diff options
Diffstat (limited to 'src/mame/includes')
49 files changed, 96 insertions, 95 deletions
diff --git a/src/mame/includes/abc80x.h b/src/mame/includes/abc80x.h index b1553305520..fa7f6e88418 100644 --- a/src/mame/includes/abc80x.h +++ b/src/mame/includes/abc80x.h @@ -25,8 +25,8 @@ // MACROS / CONSTANTS //************************************************************************** -#define ABC800_X01 XTAL_12MHz -#define ABC806_X02 XTAL_32_768kHz +#define ABC800_X01 XTAL(12'000'000) +#define ABC806_X02 XTAL(32'768) #define ABC802_AT0 0x01 #define ABC802_AT1 0x02 diff --git a/src/mame/includes/aim65.h b/src/mame/includes/aim65.h index 9db8b749bd0..ddd5bdd1b12 100644 --- a/src/mame/includes/aim65.h +++ b/src/mame/includes/aim65.h @@ -29,7 +29,7 @@ * crystal controlled oscillator. Dual D-type flip-flop Z10 divides the 4 MHz * signal by four to drive the R6502 phase 0 (O0) input with a 1 MHz clock. */ -#define AIM65_CLOCK XTAL_4MHz/4 +#define AIM65_CLOCK XTAL(4'000'000)/4 class aim65_state : public driver_device diff --git a/src/mame/includes/amiga.h b/src/mame/includes/amiga.h index 7a6fcbb0a8d..8efcea63582 100644 --- a/src/mame/includes/amiga.h +++ b/src/mame/includes/amiga.h @@ -463,15 +463,15 @@ public: DECLARE_WRITE_LINE_MEMBER(fdc_dsksyn_w); // standard clocks - static const int CLK_28M_PAL = XTAL_28_37516MHz; - static const int CLK_7M_PAL = CLK_28M_PAL / 4; - static const int CLK_C1_PAL = CLK_28M_PAL / 8; - static const int CLK_E_PAL = CLK_7M_PAL / 10; - - static const int CLK_28M_NTSC = XTAL_28_63636MHz; - static const int CLK_7M_NTSC = CLK_28M_NTSC / 4; - static const int CLK_C1_NTSC = CLK_28M_NTSC / 8; - static const int CLK_E_NTSC = CLK_7M_NTSC / 10; + static constexpr auto CLK_28M_PAL = XTAL(28'375'160); + static constexpr auto CLK_7M_PAL = CLK_28M_PAL / 4; + static constexpr auto CLK_C1_PAL = CLK_28M_PAL / 8; + static constexpr auto CLK_E_PAL = CLK_7M_PAL / 10; + + static constexpr auto CLK_28M_NTSC = XTAL(28'636'363); + static constexpr auto CLK_7M_NTSC = CLK_28M_NTSC / 4; + static constexpr auto CLK_C1_NTSC = CLK_28M_NTSC / 8; + static constexpr auto CLK_E_NTSC = CLK_7M_NTSC / 10; // screen layout enum diff --git a/src/mame/includes/apple2gs.h b/src/mame/includes/apple2gs.h index fb897ae331e..8d67258d55a 100644 --- a/src/mame/includes/apple2gs.h +++ b/src/mame/includes/apple2gs.h @@ -26,7 +26,7 @@ #define RS232B_TAG "modem" // IIgs clocks as marked on the schematics -#define APPLE2GS_28M (XTAL_28_63636MHz) // IIGS master clock +#define APPLE2GS_28M (XTAL(28'636'363)) // IIGS master clock #define APPLE2GS_14M (APPLE2GS_28M/2) #define APPLE2GS_7M (APPLE2GS_28M/4) diff --git a/src/mame/includes/astrocde.h b/src/mame/includes/astrocde.h index 4f4c7582953..c0f2f31b52e 100644 --- a/src/mame/includes/astrocde.h +++ b/src/mame/includes/astrocde.h @@ -13,7 +13,7 @@ #include "sound/votrax.h" #include "screen.h" -#define ASTROCADE_CLOCK (XTAL_14_31818MHz/2) +#define ASTROCADE_CLOCK (XTAL(14'318'181)/2) #define AC_SOUND_PRESENT (0x01) #define AC_LIGHTPEN_INTS (0x02) diff --git a/src/mame/includes/atarist.h b/src/mame/includes/atarist.h index 7455667a3ef..f015381dad8 100644 --- a/src/mame/includes/atarist.h +++ b/src/mame/includes/atarist.h @@ -39,13 +39,13 @@ // Atari ST -#define Y1 XTAL_2_4576MHz +#define Y1 XTAL(2'457'600) // STBook -#define U517 XTAL_16MHz -#define Y200 XTAL_2_4576MHz -#define Y700 XTAL_10MHz +#define U517 XTAL(16'000'000) +#define Y200 XTAL(2'457'600) +#define Y700 XTAL(10'000'000) #define DMA_STATUS_DRQ 0x04 #define DMA_STATUS_SECTOR_COUNT 0x02 diff --git a/src/mame/includes/atom.h b/src/mame/includes/atom.h index 990331a1095..0d21fd98489 100644 --- a/src/mame/includes/atom.h +++ b/src/mame/includes/atom.h @@ -38,8 +38,8 @@ #define BASERAM_TAG "baseram" -#define X1 XTAL_3_579545MHz // MC6847 Clock -#define X2 XTAL_4MHz // CPU Clock - a divider reduces it to 1MHz +#define X1 XTAL(3'579'545) // MC6847 Clock +#define X2 XTAL(4'000'000) // CPU Clock - a divider reduces it to 1MHz class atom_state : public driver_device { diff --git a/src/mame/includes/bagman.h b/src/mame/includes/bagman.h index 469c81e0bbe..9b6c3badb46 100644 --- a/src/mame/includes/bagman.h +++ b/src/mame/includes/bagman.h @@ -90,7 +90,7 @@ public: /*----------- timings -----------*/ -#define BAGMAN_MAIN_CLOCK XTAL_18_432MHz +#define BAGMAN_MAIN_CLOCK XTAL(18'432'000) #define BAGMAN_HCLK (BAGMAN_MAIN_CLOCK / 3) #define BAGMAN_H0 (BAGMAN_HCLK / 2) #define BAGMAN_H1 (BAGMAN_H0 / 2) diff --git a/src/mame/includes/bishi.h b/src/mame/includes/bishi.h index 279f1fdaab0..173900f033c 100644 --- a/src/mame/includes/bishi.h +++ b/src/mame/includes/bishi.h @@ -13,8 +13,8 @@ #include "video/konami_helper.h" #include "screen.h" -#define CPU_CLOCK (XTAL_24MHz / 2) /* 68000 clock */ -#define SOUND_CLOCK XTAL_16_9344MHz /* YMZ280 clock */ +#define CPU_CLOCK (XTAL(24'000'000) / 2) /* 68000 clock */ +#define SOUND_CLOCK XTAL(16'934'400) /* YMZ280 clock */ class bishi_state : public driver_device { diff --git a/src/mame/includes/bwidow.h b/src/mame/includes/bwidow.h index c2fd4fffedf..559aaf58531 100644 --- a/src/mame/includes/bwidow.h +++ b/src/mame/includes/bwidow.h @@ -4,8 +4,8 @@ #ifndef BWIDOW_H_ #define BWIDOW_H_ -#define MASTER_CLOCK (XTAL_12_096MHz) -#define CLOCK_3KHZ ((double)MASTER_CLOCK / 4096) +#define MASTER_CLOCK (XTAL(12'096'000)) +#define CLOCK_3KHZ (MASTER_CLOCK / 4096) class bwidow_state : public driver_device diff --git a/src/mame/includes/bzone.h b/src/mame/includes/bzone.h index 601fcbf3282..fbfde507639 100644 --- a/src/mame/includes/bzone.h +++ b/src/mame/includes/bzone.h @@ -10,8 +10,8 @@ #include "machine/mathbox.h" #include "sound/discrete.h" -#define BZONE_MASTER_CLOCK (XTAL_12_096MHz) -#define BZONE_CLOCK_3KHZ ((double)BZONE_MASTER_CLOCK / 4096) +#define BZONE_MASTER_CLOCK (XTAL(12'096'000)) +#define BZONE_CLOCK_3KHZ (BZONE_MASTER_CLOCK / 4096) class bzone_state : public driver_device { diff --git a/src/mame/includes/cdi.h b/src/mame/includes/cdi.h index c835a87bcd6..570983327c1 100644 --- a/src/mame/includes/cdi.h +++ b/src/mame/includes/cdi.h @@ -12,8 +12,8 @@ /*----------- driver state -----------*/ -#define CLOCK_A XTAL_30MHz -#define CLOCK_B XTAL_19_6608MHz +#define CLOCK_A XTAL(30'000'000) +#define CLOCK_B XTAL(19'660'800) class cdi_state : public driver_device { diff --git a/src/mame/includes/cidelsa.h b/src/mame/includes/cidelsa.h index e7743662804..4f09b21e6fc 100644 --- a/src/mame/includes/cidelsa.h +++ b/src/mame/includes/cidelsa.h @@ -21,12 +21,12 @@ #define AY8910_TAG "ay8910" #define DESTRYER_CHR1 3579000.0 // unverified -#define DESTRYER_CHR2 XTAL_5_7143MHz +#define DESTRYER_CHR2 XTAL(5'714'300) #define ALTAIR_CHR1 3579000.0 // unverified #define ALTAIR_CHR2 cdp1869_device::DOT_CLK_PAL // unverified -#define DRACO_CHR1 XTAL_4_43361MHz +#define DRACO_CHR1 XTAL(4'433'610) #define DRACO_CHR2 cdp1869_device::DOT_CLK_PAL // unverified -#define DRACO_SND_CHR1 XTAL_2_01216MHz +#define DRACO_SND_CHR1 XTAL(2'012'160) #define CIDELSA_PAGERAM_SIZE 0x400 #define DRACO_PAGERAM_SIZE 0x800 diff --git a/src/mame/includes/cosmic.h b/src/mame/includes/cosmic.h index 2d327fabc84..739b369ac43 100644 --- a/src/mame/includes/cosmic.h +++ b/src/mame/includes/cosmic.h @@ -11,8 +11,8 @@ #include "sound/dac.h" #include "screen.h" -#define COSMICG_MASTER_CLOCK XTAL_9_828MHz -#define Z80_MASTER_CLOCK XTAL_10_816MHz +#define COSMICG_MASTER_CLOCK XTAL(9'828'000) +#define Z80_MASTER_CLOCK XTAL(10'816'000) class cosmic_state : public driver_device diff --git a/src/mame/includes/cps1.h b/src/mame/includes/cps1.h index ee81999ec7c..3023c5566cd 100644 --- a/src/mame/includes/cps1.h +++ b/src/mame/includes/cps1.h @@ -30,7 +30,7 @@ Frame size: 262 scanlines Refresh rate: 59.63 MHz. */ -#define CPS_PIXEL_CLOCK (XTAL_16MHz/2) +#define CPS_PIXEL_CLOCK (XTAL(16'000'000)/2) #define CPS_HTOTAL (512) #define CPS_HBEND (64) diff --git a/src/mame/includes/crbaloon.h b/src/mame/includes/crbaloon.h index 1945f18f96a..70a4558b5c9 100644 --- a/src/mame/includes/crbaloon.h +++ b/src/mame/includes/crbaloon.h @@ -9,7 +9,7 @@ Crazy Ballooon #include "sound/discrete.h" #include "sound/sn76477.h" -#define CRBALOON_MASTER_XTAL (XTAL_9_987MHz) +#define CRBALOON_MASTER_XTAL (XTAL(9'987'000)) class crbaloon_state : public driver_device diff --git a/src/mame/includes/crgolf.h b/src/mame/includes/crgolf.h index a03f52ccbff..84ff4825603 100644 --- a/src/mame/includes/crgolf.h +++ b/src/mame/includes/crgolf.h @@ -7,7 +7,7 @@ **************************************************************************/ #include "sound/msm5205.h" #include "machine/bankdev.h" -#define MASTER_CLOCK XTAL_18_432MHz +#define MASTER_CLOCK XTAL(18'432'000) class crgolf_state : public driver_device diff --git a/src/mame/includes/divebomb.h b/src/mame/includes/divebomb.h index 5a18807a365..98da0682c5d 100644 --- a/src/mame/includes/divebomb.h +++ b/src/mame/includes/divebomb.h @@ -10,7 +10,7 @@ #include "sound/sn76496.h" #include "video/k051316.h" -#define XTAL1 XTAL_24MHz +#define XTAL1 XTAL(24'000'000) class divebomb_state : public driver_device { diff --git a/src/mame/includes/dkong.h b/src/mame/includes/dkong.h index d47b547d56f..0455d287b9d 100644 --- a/src/mame/includes/dkong.h +++ b/src/mame/includes/dkong.h @@ -41,7 +41,7 @@ * 256VF is not being used, so counting is from 248...255, 0...255, .... */ -#define MASTER_CLOCK XTAL_61_44MHz +#define MASTER_CLOCK XTAL(61'440'000) #define CLOCK_1H (MASTER_CLOCK / 5 / 4) #define CLOCK_16H (CLOCK_1H / 16) #define CLOCK_1VF ((CLOCK_16H) / 12 / 2) @@ -55,7 +55,7 @@ #define VBSTART (240) #define VBEND (16) -#define I8035_CLOCK (XTAL_6MHz) +#define I8035_CLOCK (XTAL(6'000'000)) /**************************************************************************** * CONSTANTS diff --git a/src/mame/includes/esripsys.h b/src/mame/includes/esripsys.h index a9a261c260c..bcbc7398795 100644 --- a/src/mame/includes/esripsys.h +++ b/src/mame/includes/esripsys.h @@ -17,7 +17,7 @@ #include "screen.h" /* TODO */ -#define ESRIPSYS_PIXEL_CLOCK (XTAL_25MHz / 2) +#define ESRIPSYS_PIXEL_CLOCK (XTAL(25'000'000) / 2) #define ESRIPSYS_HTOTAL (512 + 141 + 2) #define ESRIPSYS_HBLANK_START (512) #define ESRIPSYS_HBLANK_END (0) diff --git a/src/mame/includes/exerion.h b/src/mame/includes/exerion.h index c96ad806ccf..7909a742ee4 100644 --- a/src/mame/includes/exerion.h +++ b/src/mame/includes/exerion.h @@ -8,7 +8,7 @@ #include "screen.h" -#define EXERION_MASTER_CLOCK (XTAL_19_968MHz) /* verified on pcb */ +#define EXERION_MASTER_CLOCK (XTAL(19'968'000)) /* verified on pcb */ #define EXERION_CPU_CLOCK (EXERION_MASTER_CLOCK / 6) #define EXERION_AY8910_CLOCK (EXERION_CPU_CLOCK / 2) #define EXERION_PIXEL_CLOCK (EXERION_MASTER_CLOCK / 3) diff --git a/src/mame/includes/exidy.h b/src/mame/includes/exidy.h index 90db0aa04ec..7179192e9e0 100644 --- a/src/mame/includes/exidy.h +++ b/src/mame/includes/exidy.h @@ -10,7 +10,7 @@ #include "sound/samples.h" #include "screen.h" -#define EXIDY_MASTER_CLOCK (XTAL_11_289MHz) +#define EXIDY_MASTER_CLOCK (XTAL(11'289'000)) #define EXIDY_CPU_CLOCK (EXIDY_MASTER_CLOCK / 16) #define EXIDY_PIXEL_CLOCK (EXIDY_MASTER_CLOCK / 2) #define EXIDY_HTOTAL (0x150) diff --git a/src/mame/includes/exidy440.h b/src/mame/includes/exidy440.h index cc812d32b80..c87bee1178d 100644 --- a/src/mame/includes/exidy440.h +++ b/src/mame/includes/exidy440.h @@ -9,7 +9,7 @@ #include "audio/exidy440.h" #include "screen.h" -#define EXIDY440_MASTER_CLOCK (XTAL_12_9792MHz) +#define EXIDY440_MASTER_CLOCK (XTAL(12'979'200)) class exidy440_state : public driver_device diff --git a/src/mame/includes/fuukifg3.h b/src/mame/includes/fuukifg3.h index 72265195bbd..139ca904c57 100644 --- a/src/mame/includes/fuukifg3.h +++ b/src/mame/includes/fuukifg3.h @@ -5,9 +5,9 @@ /* Define clocks based on actual OSC on the PCB */ -#define CPU_CLOCK (XTAL_40MHz / 2) /* clock for 68020 */ -#define SOUND_CPU_CLOCK (XTAL_12MHz / 2) /* clock for Z80 sound CPU */ -#define FM_SOUND_CLOCK (XTAL_33_8688MHz / 2) /* FM clock */ +#define CPU_CLOCK (XTAL(40'000'000) / 2) /* clock for 68020 */ +#define SOUND_CPU_CLOCK (XTAL(12'000'000) / 2) /* clock for Z80 sound CPU */ +#define FM_SOUND_CLOCK (XTAL(33'868'800) / 2) /* FM clock */ /* NOTE: YMF278B_STD_CLOCK is defined in /src/emu/sound/ymf278b.h */ diff --git a/src/mame/includes/galaxian.h b/src/mame/includes/galaxian.h index 9f498f4fc05..9f847751e78 100644 --- a/src/mame/includes/galaxian.h +++ b/src/mame/includes/galaxian.h @@ -18,7 +18,7 @@ #define GALAXIAN_XSCALE 3 /* master clocks */ -#define GALAXIAN_MASTER_CLOCK (XTAL_18_432MHz) +#define GALAXIAN_MASTER_CLOCK (XTAL(18'432'000)) #define GALAXIAN_PIXEL_CLOCK (GALAXIAN_XSCALE*GALAXIAN_MASTER_CLOCK/3) /* H counts from 128->511, HBLANK starts at 130 and ends at 250 */ diff --git a/src/mame/includes/gameplan.h b/src/mame/includes/gameplan.h index 372c1b8b479..e2241755398 100644 --- a/src/mame/includes/gameplan.h +++ b/src/mame/includes/gameplan.h @@ -13,16 +13,16 @@ driver by Chris Moore #include "machine/gen_latch.h" #include "screen.h" -#define GAMEPLAN_MAIN_MASTER_CLOCK (XTAL_3_579545MHz) -#define GAMEPLAN_AUDIO_MASTER_CLOCK (XTAL_3_579545MHz) +#define GAMEPLAN_MAIN_MASTER_CLOCK (XTAL(3'579'545)) +#define GAMEPLAN_AUDIO_MASTER_CLOCK (XTAL(3'579'545)) #define GAMEPLAN_MAIN_CPU_CLOCK (GAMEPLAN_MAIN_MASTER_CLOCK / 4) #define GAMEPLAN_AUDIO_CPU_CLOCK (GAMEPLAN_AUDIO_MASTER_CLOCK / 4) #define GAMEPLAN_AY8910_CLOCK (GAMEPLAN_AUDIO_MASTER_CLOCK / 2) -#define GAMEPLAN_PIXEL_CLOCK (XTAL_11_6688MHz / 2) +#define GAMEPLAN_PIXEL_CLOCK (XTAL(11'668'800) / 2) /* Used Leprechaun/Pot of Gold (and Pirate Treasure) - as stated in manual for Pot Of Gold */ -#define LEPRECHAUN_MAIN_MASTER_CLOCK (XTAL_4MHz) +#define LEPRECHAUN_MAIN_MASTER_CLOCK (XTAL(4'000'000)) #define LEPRECHAUN_MAIN_CPU_CLOCK (LEPRECHAUN_MAIN_MASTER_CLOCK / 4) diff --git a/src/mame/includes/harddriv.h b/src/mame/includes/harddriv.h index 1ade185e0b5..649b9bbc119 100644 --- a/src/mame/includes/harddriv.h +++ b/src/mame/includes/harddriv.h @@ -31,8 +31,8 @@ #include "screen.h" -#define HARDDRIV_MASTER_CLOCK XTAL_32MHz -#define HARDDRIV_GSP_CLOCK XTAL_48MHz +#define HARDDRIV_MASTER_CLOCK XTAL(32'000'000) +#define HARDDRIV_GSP_CLOCK XTAL(48'000'000) DECLARE_DEVICE_TYPE(HARDDRIV_BOARD, harddriv_board_device_state) DECLARE_DEVICE_TYPE(HARDDRIVC_BOARD, harddrivc_board_device_state) diff --git a/src/mame/includes/itech32.h b/src/mame/includes/itech32.h index 7f9d4030616..7c282d6c1b4 100644 --- a/src/mame/includes/itech32.h +++ b/src/mame/includes/itech32.h @@ -11,11 +11,11 @@ #include "machine/ticket.h" #include "screen.h" -#define VIDEO_CLOCK XTAL_8MHz /* video (pixel) clock */ -#define CPU_CLOCK XTAL_12MHz /* clock for 68000-based systems */ -#define CPU020_CLOCK XTAL_25MHz /* clock for 68EC020-based systems */ -#define SOUND_CLOCK XTAL_16MHz /* clock for sound board */ -#define TMS_CLOCK XTAL_40MHz /* TMS320C31 clocks on drivedge */ +#define VIDEO_CLOCK XTAL(8'000'000) /* video (pixel) clock */ +#define CPU_CLOCK XTAL(12'000'000) /* clock for 68000-based systems */ +#define CPU020_CLOCK XTAL(25'000'000) /* clock for 68EC020-based systems */ +#define SOUND_CLOCK XTAL(16'000'000) /* clock for sound board */ +#define TMS_CLOCK XTAL(40'000'000) /* TMS320C31 clocks on drivedge */ class itech32_state : public driver_device diff --git a/src/mame/includes/jackal.h b/src/mame/includes/jackal.h index 38825563609..5b5a8657a2d 100644 --- a/src/mame/includes/jackal.h +++ b/src/mame/includes/jackal.h @@ -2,8 +2,8 @@ // copyright-holders:Curt Coder // thanks-to:Kenneth Lin (original driver author) -#define MASTER_CLOCK XTAL_18_432MHz -#define SOUND_CLOCK XTAL_3_579545MHz +#define MASTER_CLOCK XTAL(18'432'000) +#define SOUND_CLOCK XTAL(3'579'545) diff --git a/src/mame/includes/jaguar.h b/src/mame/includes/jaguar.h index 660f8f5661f..b282ae22a83 100644 --- a/src/mame/includes/jaguar.h +++ b/src/mame/includes/jaguar.h @@ -21,9 +21,9 @@ #endif /* CoJag and Jaguar have completely different XTALs, pixel clock in Jaguar is the same as the GPU one */ -#define COJAG_PIXEL_CLOCK XTAL_14_31818MHz -#define JAGUAR_CLOCK XTAL_25_590906MHz // NTSC -// XTAL_25_593900MHz PAL, TODO +#define COJAG_PIXEL_CLOCK XTAL(14'318'181) +#define JAGUAR_CLOCK XTAL(25'590'906) // NTSC +// XTAL(25'593'900) PAL, TODO class jaguar_state : public driver_device { diff --git a/src/mame/includes/jailbrek.h b/src/mame/includes/jailbrek.h index d71ed321855..9c08d84a959 100644 --- a/src/mame/includes/jailbrek.h +++ b/src/mame/includes/jailbrek.h @@ -8,8 +8,8 @@ #include "sound/vlm5030.h" -#define MASTER_CLOCK XTAL_18_432MHz -#define VOICE_CLOCK XTAL_3_579545MHz +#define MASTER_CLOCK XTAL(18'432'000) +#define VOICE_CLOCK XTAL(3'579'545) class jailbrek_state : public driver_device { diff --git a/src/mame/includes/jedi.h b/src/mame/includes/jedi.h index a3dda068fa4..5b3aff7f54b 100644 --- a/src/mame/includes/jedi.h +++ b/src/mame/includes/jedi.h @@ -10,8 +10,8 @@ /* oscillators and clocks */ -#define JEDI_MAIN_CPU_OSC (XTAL_10MHz) -#define JEDI_AUDIO_CPU_OSC (XTAL_12_096MHz) +#define JEDI_MAIN_CPU_OSC (XTAL(10'000'000)) +#define JEDI_AUDIO_CPU_OSC (XTAL(12'096'000)) #define JEDI_MAIN_CPU_CLOCK (JEDI_MAIN_CPU_OSC / 4) #define JEDI_AUDIO_CPU_CLOCK (JEDI_AUDIO_CPU_OSC / 8) #define JEDI_POKEY_CLOCK (JEDI_AUDIO_CPU_CLOCK) diff --git a/src/mame/includes/lockon.h b/src/mame/includes/lockon.h index 913c50029a0..771bf2c903a 100644 --- a/src/mame/includes/lockon.h +++ b/src/mame/includes/lockon.h @@ -11,8 +11,8 @@ #include "screen.h" /* Calculated from CRT controller writes */ -#define PIXEL_CLOCK (XTAL_21MHz / 3) -#define FRAMEBUFFER_CLOCK XTAL_10MHz +#define PIXEL_CLOCK (XTAL(21'000'000) / 3) +#define FRAMEBUFFER_CLOCK XTAL(10'000'000) #define HBSTART 320 #define HBEND 0 #define HTOTAL 448 diff --git a/src/mame/includes/madalien.h b/src/mame/includes/madalien.h index 29ea08483e8..aca5d66308d 100644 --- a/src/mame/includes/madalien.h +++ b/src/mame/includes/madalien.h @@ -12,7 +12,7 @@ #include "sound/discrete.h" -#define MADALIEN_MAIN_CLOCK XTAL_10_595MHz +#define MADALIEN_MAIN_CLOCK XTAL(10'595'000) class madalien_state : public driver_device diff --git a/src/mame/includes/mario.h b/src/mame/includes/mario.h index 36d6730059d..225b5c86ad4 100644 --- a/src/mame/includes/mario.h +++ b/src/mame/includes/mario.h @@ -22,7 +22,7 @@ * 7C -> 100 => 256 - 124 = 132 ==> 264 Scanlines */ -#define MASTER_CLOCK XTAL_24MHz +#define MASTER_CLOCK XTAL(24'000'000) #define PIXEL_CLOCK (MASTER_CLOCK / 4) #define CLOCK_1H (MASTER_CLOCK / 8) #define CLOCK_16H (CLOCK_1H / 16) @@ -36,10 +36,10 @@ #define VBSTART (240) #define VBEND (16) -#define Z80_MASTER_CLOCK XTAL_8MHz +#define Z80_MASTER_CLOCK XTAL(8'000'000) #define Z80_CLOCK (Z80_MASTER_CLOCK / 2) /* verified on pcb */ -#define I8035_MASTER_CLOCK XTAL_11MHz /* verified on pcb: 730Khz */ +#define I8035_MASTER_CLOCK XTAL(11'000'000) /* verified on pcb: 730Khz */ #define I8035_CLOCK (I8035_MASTER_CLOCK) class mario_state : public driver_device diff --git a/src/mame/includes/maygay1b.h b/src/mame/includes/maygay1b.h index d8536adebe4..d9800286763 100644 --- a/src/mame/includes/maygay1b.h +++ b/src/mame/includes/maygay1b.h @@ -6,8 +6,8 @@ #define VERBOSE 0 #define LOG(x) do { if (VERBOSE) logerror x; } while (0) -#define M1_MASTER_CLOCK (XTAL_8MHz) -#define M1_DUART_CLOCK (XTAL_3_6864MHz) +#define M1_MASTER_CLOCK (XTAL(8'000'000)) +#define M1_DUART_CLOCK (XTAL(3'686'400)) #include "cpu/m6809/m6809.h" #include "machine/i8279.h" diff --git a/src/mame/includes/mcr.h b/src/mame/includes/mcr.h index 0a800da08f6..e450bd7b3d2 100644 --- a/src/mame/includes/mcr.h +++ b/src/mame/includes/mcr.h @@ -18,7 +18,7 @@ #include "sound/samples.h" /* constants */ -#define MAIN_OSC_MCR_I XTAL_19_968MHz +#define MAIN_OSC_MCR_I XTAL(19'968'000) class mcr_state : public driver_device diff --git a/src/mame/includes/midzeus.h b/src/mame/includes/midzeus.h index 2f17721b2cd..f262f5327a3 100644 --- a/src/mame/includes/midzeus.h +++ b/src/mame/includes/midzeus.h @@ -6,7 +6,7 @@ **************************************************************************/ -#define MIDZEUS_VIDEO_CLOCK XTAL_66_6667MHz +#define MIDZEUS_VIDEO_CLOCK XTAL(66'666'700) #include "machine/timekpr.h" #include "screen.h" diff --git a/src/mame/includes/mpu4.h b/src/mame/includes/mpu4.h index 4d3dae267f5..412132c9b41 100644 --- a/src/mame/includes/mpu4.h +++ b/src/mame/includes/mpu4.h @@ -16,8 +16,8 @@ #include "machine/meters.h" -#define MPU4_MASTER_CLOCK XTAL_6_88MHz -#define VIDEO_MASTER_CLOCK XTAL_10MHz +#define MPU4_MASTER_CLOCK XTAL(6'880'000) +#define VIDEO_MASTER_CLOCK XTAL(10'000'000) #ifdef MAME_DEBUG diff --git a/src/mame/includes/mystston.h b/src/mame/includes/mystston.h index 953a20efc2b..024adacc6ba 100644 --- a/src/mame/includes/mystston.h +++ b/src/mame/includes/mystston.h @@ -11,7 +11,7 @@ #include "screen.h" -#define MYSTSTON_MASTER_CLOCK (XTAL_12MHz) +#define MYSTSTON_MASTER_CLOCK (XTAL(12'000'000)) class mystston_state : public driver_device diff --git a/src/mame/includes/osi.h b/src/mame/includes/osi.h index 533cd1705f4..485204bf31c 100644 --- a/src/mame/includes/osi.h +++ b/src/mame/includes/osi.h @@ -21,7 +21,7 @@ #define DISCRETE_TAG "discrete" #define X1 3932160 -#define UK101_X1 XTAL_8MHz +#define UK101_X1 XTAL(8'000'000) #define OSI600_VIDEORAM_SIZE 0x400 #define OSI630_COLORRAM_SIZE 0x400 diff --git a/src/mame/includes/phoenix.h b/src/mame/includes/phoenix.h index e2df7565ac6..9fb42207c03 100644 --- a/src/mame/includes/phoenix.h +++ b/src/mame/includes/phoenix.h @@ -67,7 +67,7 @@ protected: /*----------- video timing -----------*/ -#define MASTER_CLOCK XTAL_11MHz +#define MASTER_CLOCK XTAL(11'000'000) #define PIXEL_CLOCK (MASTER_CLOCK/2) #define CPU_CLOCK (PIXEL_CLOCK) diff --git a/src/mame/includes/polyplay.h b/src/mame/includes/polyplay.h index 1b17cc61287..9b284d27c6d 100644 --- a/src/mame/includes/polyplay.h +++ b/src/mame/includes/polyplay.h @@ -9,7 +9,7 @@ #include "machine/z80sio.h" #include "sound/spkrdev.h" -#define POLYPLAY_MAIN_CLOCK XTAL_9_8304MHz +#define POLYPLAY_MAIN_CLOCK XTAL(9'830'400) #define Z80CPU_TAG "maincpu" #define Z80CTC_TAG "z80ctc" diff --git a/src/mame/includes/s11.h b/src/mame/includes/s11.h index 8165cdfbfba..0aeafeeff23 100644 --- a/src/mame/includes/s11.h +++ b/src/mame/includes/s11.h @@ -18,7 +18,7 @@ // 6802/8 CPU's input clock is 4MHz // but because it has an internal /4 divider, its E clock runs at 1/4 that frequency -#define E_CLOCK (XTAL_4MHz/4) +#define E_CLOCK (XTAL(4'000'000)/4) // Length of time in cycles between IRQs on the main 6808 CPU // This length is determined by the settings of the W14 and W15 jumpers diff --git a/src/mame/includes/saturn.h b/src/mame/includes/saturn.h index fbd8e7613ec..5812c4599b9 100644 --- a/src/mame/includes/saturn.h +++ b/src/mame/includes/saturn.h @@ -612,8 +612,9 @@ public: }; -#define MASTER_CLOCK_352 XTAL_57_2727MHz -#define MASTER_CLOCK_320 XTAL_53_693175MHz +// These two clocks are synthesized by the 315-5746 +#define MASTER_CLOCK_352 XTAL(14'318'181)*4 +#define MASTER_CLOCK_320 XTAL(14'318'181)*3.75 #define CEF_1 m_vdp1_regs[0x010/2]|=0x0002 #define CEF_0 m_vdp1_regs[0x010/2]&=~0x0002 #define BEF_1 m_vdp1_regs[0x010/2]|=0x0001 diff --git a/src/mame/includes/spectrum.h b/src/mame/includes/spectrum.h index d227e10e58c..2b75781ab68 100644 --- a/src/mame/includes/spectrum.h +++ b/src/mame/includes/spectrum.h @@ -24,11 +24,11 @@ /* Spectrum crystals */ -#define X1 XTAL_14MHz // Main clock (48k Spectrum) +#define X1 XTAL(14'000'000) // Main clock (48k Spectrum) #define X1_128_AMSTRAD 35469000 // Main clock (Amstrad 128K model, +2A?) #define X1_128_SINCLAIR 17734475 // Main clock (Sinclair 128K model) -#define X2 XTAL_4_433619MHz // PAL color subcarrier +#define X2 XTAL(4'433'619) // PAL color subcarrier /* Spectrum screen size in pixels */ #define SPEC_UNSEEN_LINES 16 /* Non-visible scanlines before first border diff --git a/src/mame/includes/starfire.h b/src/mame/includes/starfire.h index d298f7901b3..efed6938214 100644 --- a/src/mame/includes/starfire.h +++ b/src/mame/includes/starfire.h @@ -10,7 +10,7 @@ #include "screen.h" -#define STARFIRE_MASTER_CLOCK (XTAL_20MHz) +#define STARFIRE_MASTER_CLOCK (XTAL(20'000'000)) #define STARFIRE_CPU_CLOCK (STARFIRE_MASTER_CLOCK / 8) #define STARFIRE_PIXEL_CLOCK (STARFIRE_MASTER_CLOCK / 4) #define STARFIRE_HTOTAL (0x13f) /* could be 0x140, but I think this is right */ diff --git a/src/mame/includes/tx1.h b/src/mame/includes/tx1.h index 3c1927f7b8f..98779e583b1 100644 --- a/src/mame/includes/tx1.h +++ b/src/mame/includes/tx1.h @@ -13,7 +13,7 @@ #include "screen.h" -#define TX1_PIXEL_CLOCK (XTAL_18MHz / 3) +#define TX1_PIXEL_CLOCK (XTAL(18'000'000) / 3) #define TX1_HBSTART 256 #define TX1_HBEND 0 #define TX1_HTOTAL 384 @@ -26,7 +26,7 @@ * that prevents one of the start countdown tones * from playing. */ -#define BB_PIXEL_CLOCK (XTAL_18MHz / 3) +#define BB_PIXEL_CLOCK (XTAL(18'000'000) / 3) #define BB_HBSTART 256 #define BB_HBEND 0 #define BB_HTOTAL 384 @@ -34,7 +34,7 @@ #define BB_VBEND 0 #define BB_VTOTAL 288 + 1 -#define CPU_MASTER_CLOCK (XTAL_15MHz) +#define CPU_MASTER_CLOCK (XTAL(15'000'000)) #define BUGGYBOY_ZCLK (CPU_MASTER_CLOCK / 2) struct math_t diff --git a/src/mame/includes/victory.h b/src/mame/includes/victory.h index 9cf5941860e..6358f0500c0 100644 --- a/src/mame/includes/victory.h +++ b/src/mame/includes/victory.h @@ -9,9 +9,9 @@ #include "screen.h" -#define VICTORY_MAIN_CPU_CLOCK (XTAL_8MHz / 2) +#define VICTORY_MAIN_CPU_CLOCK (XTAL(8'000'000) / 2) -#define VICTORY_PIXEL_CLOCK (XTAL_11_289MHz / 2) +#define VICTORY_PIXEL_CLOCK (XTAL(11'289'000) / 2) #define VICTORY_HTOTAL (0x150) #define VICTORY_HBEND (0x000) #define VICTORY_HBSTART (0x100) |