From f7daafde0fa1c20b8188fa409cbd98273fabb5cc Mon Sep 17 00:00:00 2001 From: Vas Crabb Date: Sat, 14 Dec 2024 06:03:55 +1100 Subject: dynax/ddenlovr.cpp, dynax/dynax.cpp: Improved DIP switches for mjflove and mjdialq2. More updates based on manuals and playing the games. Also some random cleanup and Coverity warning fixes. --- src/devices/bus/heathzenith/h89/cdr_fdc_880h.cpp | 86 ++++++++++--------- src/devices/bus/heathzenith/h89/cdr_fdc_880h.h | 1 - src/devices/cpu/m6800/m6800.cpp | 6 +- src/mame/apple/apple2video.h | 16 ++-- src/mame/dynax/ddenlovr.cpp | 70 ++++++++-------- src/mame/dynax/dynax.cpp | 100 +++++++++++------------ src/mame/shared/xbox_nv2a.cpp | 7 +- 7 files changed, 141 insertions(+), 145 deletions(-) diff --git a/src/devices/bus/heathzenith/h89/cdr_fdc_880h.cpp b/src/devices/bus/heathzenith/h89/cdr_fdc_880h.cpp index 21ca7209c9a..ed33daa4a88 100644 --- a/src/devices/bus/heathzenith/h89/cdr_fdc_880h.cpp +++ b/src/devices/bus/heathzenith/h89/cdr_fdc_880h.cpp @@ -15,12 +15,38 @@ #include "imagedev/floppy.h" #include "machine/wd_fdc.h" +#define LOG_REG (1U << 1) // Shows register setup +#define LOG_LINES (1U << 2) // Show control lines +#define LOG_DRIVE (1U << 3) // Show drive select +#define LOG_FUNC (1U << 4) // Function calls +#define LOG_ERR (1U << 5) // log errors +#define LOG_WAIT (1U << 6) // wait mode +#define LOG_DATA (1U << 7) // data read/writes + +#define VERBOSE (0xff) + +#include "logmacro.h" + +#define LOGREG(...) LOGMASKED(LOG_REG, __VA_ARGS__) +#define LOGLINES(...) LOGMASKED(LOG_LINES, __VA_ARGS__) +#define LOGDRIVE(...) LOGMASKED(LOG_DRIVE, __VA_ARGS__) +#define LOGFUNC(...) LOGMASKED(LOG_FUNC, __VA_ARGS__) +#define LOGERR(...) LOGMASKED(LOG_ERR, __VA_ARGS__) +#define LOGWAIT(...) LOGMASKED(LOG_WAIT, __VA_ARGS__) +#define LOGDATA(...) LOGMASKED(LOG_DATA, __VA_ARGS__) + +#ifdef _MSC_VER +#define FUNCNAME __func__ +#else +#define FUNCNAME __PRETTY_FUNCTION__ +#endif + + namespace { class cdr_fdc_880h_device : public device_t, public device_h89bus_right_card_interface { public: - cdr_fdc_880h_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); virtual void write(u8 select_lines, u8 offset, u8 data) override; @@ -31,9 +57,9 @@ public: protected: - virtual void device_start() override; - virtual void device_reset() override; - virtual void device_add_mconfig(machine_config &config) override; + virtual void device_start() override ATTR_COLD; + virtual void device_reset() override ATTR_COLD; + virtual void device_add_mconfig(machine_config &config) override ATTR_COLD; void cmd_w(u8 val); void data_w(u8 val); @@ -44,6 +70,15 @@ protected: void set_drq(int state); private: + /// Bits set in cmd_ControlPort_c + static constexpr u8 ctrl_EnableIntReq_c = 7; + static constexpr u8 ctrl_SetMFMRecording_c = 6; + static constexpr u8 ctrl_DriveType_c = 5; + static constexpr u8 ctrl_Mode_c = 4; + + static constexpr XTAL MASTER_CLOCK = XTAL(4'000'000); + static constexpr XTAL FIVE_IN_CLOCK = MASTER_CLOCK / 4; + static constexpr XTAL EIGHT_IN_CLOCK = MASTER_CLOCK / 2; required_device m_fdc; required_device_array m_floppies; @@ -57,46 +92,8 @@ private: bool m_five_in_drive; bool m_mode_operate; s8 m_drive; - - - /// Bits set in cmd_ControlPort_c - static constexpr u8 ctrl_EnableIntReq_c = 7; - static constexpr u8 ctrl_SetMFMRecording_c = 6; - static constexpr u8 ctrl_DriveType_c = 5; - static constexpr u8 ctrl_Mode_c = 4; - - static constexpr XTAL MASTER_CLOCK = XTAL(4'000'000); - static constexpr XTAL FIVE_IN_CLOCK = MASTER_CLOCK / 4; - static constexpr XTAL EIGHT_IN_CLOCK = MASTER_CLOCK / 2; - }; -#define LOG_REG (1U << 1) // Shows register setup -#define LOG_LINES (1U << 2) // Show control lines -#define LOG_DRIVE (1U << 3) // Show drive select -#define LOG_FUNC (1U << 4) // Function calls -#define LOG_ERR (1U << 5) // log errors -#define LOG_WAIT (1U << 6) // wait mode -#define LOG_DATA (1U << 7) // data read/writes - -#define VERBOSE (0xff) - -#include "logmacro.h" - -#define LOGREG(...) LOGMASKED(LOG_REG, __VA_ARGS__) -#define LOGLINES(...) LOGMASKED(LOG_LINES, __VA_ARGS__) -#define LOGDRIVE(...) LOGMASKED(LOG_DRIVE, __VA_ARGS__) -#define LOGFUNC(...) LOGMASKED(LOG_FUNC, __VA_ARGS__) -#define LOGERR(...) LOGMASKED(LOG_ERR, __VA_ARGS__) -#define LOGWAIT(...) LOGMASKED(LOG_WAIT, __VA_ARGS__) -#define LOGDATA(...) LOGMASKED(LOG_DATA, __VA_ARGS__) - -#ifdef _MSC_VER -#define FUNCNAME __func__ -#else -#define FUNCNAME __PRETTY_FUNCTION__ -#endif - cdr_fdc_880h_device::cdr_fdc_880h_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock): device_t(mconfig, H89BUS_CDR_FDC_880H, tag, owner, 0), @@ -320,12 +317,11 @@ void cdr_fdc_880h_device::device_reset() set_slot_int5(CLEAR_LINE); set_slot_wait(CLEAR_LINE); - for (int i = 0; i < 4; i++) + for (auto &elem : m_floppies) { - auto elem = m_floppies[i]; if (elem) { - floppy_image_device *floppy = elem->get_device(); + floppy_image_device *const floppy = elem->get_device(); if (floppy) { // turn on motor of all installed 8" floppies diff --git a/src/devices/bus/heathzenith/h89/cdr_fdc_880h.h b/src/devices/bus/heathzenith/h89/cdr_fdc_880h.h index 2bb62de1dea..f884da58405 100644 --- a/src/devices/bus/heathzenith/h89/cdr_fdc_880h.h +++ b/src/devices/bus/heathzenith/h89/cdr_fdc_880h.h @@ -15,5 +15,4 @@ DECLARE_DEVICE_TYPE(H89BUS_CDR_FDC_880H, device_h89bus_right_card_interface) - #endif // MAME_BUS_HEATHZENITH_H89_CDR_FDC_880H_H diff --git a/src/devices/cpu/m6800/m6800.cpp b/src/devices/cpu/m6800/m6800.cpp index 30ab10ff7b6..580a9798ea4 100644 --- a/src/devices/cpu/m6800/m6800.cpp +++ b/src/devices/cpu/m6800/m6800.cpp @@ -141,8 +141,8 @@ TODO: /* macros for CC -- CC bits affected should be reset before calling */ #define SET_Z(a) if(!(a))SEZ -#define SET_Z8(a) SET_Z((u8)(a)) -#define SET_Z16(a) SET_Z((u16)(a)) +#define SET_Z8(a) SET_Z(u8(a)) +#define SET_Z16(a) SET_Z(u16(a)) #define SET_N8(a) CC|=(((a)&0x80)>>4) #define SET_N16(a) CC|=(((a)&0x8000)>>12) #define SET_H(a,b,r) CC|=((((a)^(b)^(r))&0x10)<<1) @@ -202,7 +202,7 @@ const u8 m6800_cpu_device::flags8d[256]= /* decrement */ #define SET_FLAGS16(a,b,r) {SET_N16(r);SET_Z16(r);SET_V16(a,b,r);SET_C16(r);} /* for treating an u8 as a signed s16 */ -#define SIGNED(b) ((s16)(b&0x80?b|0xff00:b)) +#define SIGNED(b) (s16(b&0x80?b|0xff00:b)) /* Macros for addressing modes */ #define DIRECT IMMBYTE(EAD) diff --git a/src/mame/apple/apple2video.h b/src/mame/apple/apple2video.h index 02b12e51018..1a820f3c851 100644 --- a/src/mame/apple/apple2video.h +++ b/src/mame/apple/apple2video.h @@ -18,6 +18,9 @@ class a2_video_device : public device_t, public device_palette_interface, public device_video_interface { public: + // Models with different text-mode behavior. II includes the II+ and IIE includes the IIc and IIc Plus. + enum class model { II, IIE, IIGS, II_J_PLUS, IVEL_ULTRA }; + // construction/destruction a2_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); @@ -51,21 +54,18 @@ public: void set_GS_monochrome(u8 mono) { m_monochrome = mono; } void set_GS_foreground(u8 fg) { m_GSfg = fg; } void set_GS_background(u8 bg) { m_GSbg = bg; } - const u8 get_GS_border() { return m_GSborder; } + u8 get_GS_border() { return m_GSborder; } void set_GS_border(u8 border) { m_GSborder = border; } const u8 get_newvideo() { return m_newvideo; } void set_newvideo(u8 newvideo) { m_newvideo = newvideo; } - const u8 get_GS_langsel() { return m_GS_langsel; } - const u8 get_GS_language() { return (m_GS_langsel >> 5) & 0x07; } - const bool is_pal_video_mode() { return (m_GS_langsel >> 4) & 0x01; } - const bool get_language_switch(){ return (m_GS_langsel >> 3) & 0x01; } + u8 get_GS_langsel() { return m_GS_langsel; } + u8 get_GS_language() { return (m_GS_langsel >> 5) & 0x07; } + bool is_pal_video_mode() { return (m_GS_langsel >> 4) & 0x01; } + bool get_language_switch() { return (m_GS_langsel >> 3) & 0x01; } void set_GS_langsel(u8 langsel) { m_GS_langsel = langsel; } void set_SHR_color(u8 color, u32 rgb) { m_shr_palette[color] = rgb; } void set_GS_border_color(u8 color, u32 rgb) { m_GSborder_colors[color] = rgb; } - // Models with different text-mode behavior. II includes the II+ and IIE includes the IIc and IIc Plus. - enum class model { II, IIE, IIGS, II_J_PLUS, IVEL_ULTRA }; - void set_ram_pointers(u8 *main, u8 *aux) { m_ram_ptr = main; m_aux_ptr = aux; } void set_aux_mask(u16 aux_mask) { m_aux_mask = aux_mask; } void set_char_pointer(u8 *charptr, int size) { m_char_ptr = charptr; m_char_size = size; } diff --git a/src/mame/dynax/ddenlovr.cpp b/src/mame/dynax/ddenlovr.cpp index 8314af44199..1513496218b 100644 --- a/src/mame/dynax/ddenlovr.cpp +++ b/src/mame/dynax/ddenlovr.cpp @@ -7737,9 +7737,9 @@ INPUT_PORTS_END static INPUT_PORTS_START( mjflove ) PORT_START("SYSTEM") PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 ) - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME(DEF_STR( Test )) PORT_TOGGLE + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) // plays coin sound in test mode but not shown + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME(DEF_STR(Test)) PORT_TOGGLE PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_BIT( 0x60, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(FUNC(ddenlovr_state::mjflove_blitter_r)) // RTC (bit 5) & blitter irq flag (bit 6) PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_CUSTOM ) // blitter busy flag @@ -7747,41 +7747,39 @@ static INPUT_PORTS_START( mjflove ) PORT_INCLUDE( mahjong_matrix_2p_bet_wup ) PORT_START("DSW2") // IN12 - DSW2 - PORT_DIPNAME( 0x03, 0x03, DEF_STR( Coinage ) ) PORT_DIPLOCATION("SW1:1,2") - PORT_DIPSETTING( 0x02, DEF_STR( 1C_2C ) ) - PORT_DIPSETTING( 0x03, DEF_STR( 1C_1C ) ) - PORT_DIPSETTING( 0x01, DEF_STR( 2C_1C ) ) - PORT_DIPSETTING( 0x00, DEF_STR( 3C_1C ) ) - PORT_DIPNAME( 0x1c, 0x1c, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:3,4,5") - PORT_DIPSETTING( 0x18, "1" ) - PORT_DIPSETTING( 0x14, "2" ) - PORT_DIPSETTING( 0x10, "3" ) - PORT_DIPSETTING( 0x1c, "4" ) - PORT_DIPSETTING( 0x0c, "5" ) - PORT_DIPSETTING( 0x08, "6" ) - PORT_DIPSETTING( 0x04, "7" ) - PORT_DIPSETTING( 0x00, "8" ) - PORT_DIPNAME( 0x20, 0x20, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("SW1:6") - PORT_DIPSETTING( 0x20, DEF_STR( On ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPNAME( 0x40, 0x40, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION("SW1:7") - PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) - PORT_SERVICE( 0x80, IP_ACTIVE_LOW ) PORT_DIPLOCATION("SW1:8") -/* - PORT_DIPNAME( 0x80, 0x80, DEF_STR( Test ) ) PORT_DIPLOCATION("SW1:8") - PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) )*/ + PORT_DIPNAME( 0x03, 0x03, DEF_STR(Coinage) ) PORT_DIPLOCATION("SW1:1,2") // コインレート + PORT_DIPSETTING( 0x00, DEF_STR(3C_1C) ) // 3コイン  1クレジット + PORT_DIPSETTING( 0x01, DEF_STR(2C_1C) ) // 2コイン  1クレジット + PORT_DIPSETTING( 0x03, DEF_STR(1C_1C) ) // 1コイン  1クレジット + PORT_DIPSETTING( 0x02, DEF_STR(1C_2C) ) // 1コイン  2クレジット + PORT_DIPNAME( 0x1c, 0x1c, DEF_STR(Difficulty) ) PORT_DIPLOCATION("SW1:3,4,5") // 難易度 + PORT_DIPSETTING( 0x18, "1 (Weak)" ) // 1 弱い + PORT_DIPSETTING( 0x14, "2" ) // 2 + PORT_DIPSETTING( 0x10, "3" ) // 3 + PORT_DIPSETTING( 0x1c, "4 (Normal)" ) // 4 標準 + PORT_DIPSETTING( 0x0c, "5" ) // 5 + PORT_DIPSETTING( 0x08, "6" ) // 6 + PORT_DIPSETTING( 0x04, "7" ) // 7 + PORT_DIPSETTING( 0x00, "8 (Strong)" ) // 8 強い + PORT_DIPNAME( 0x20, 0x20, DEF_STR(Demo_Sounds) ) PORT_DIPLOCATION("SW1:6") // デモ音楽 + PORT_DIPSETTING( 0x00, DEF_STR(Off) ) // 無し + PORT_DIPSETTING( 0x20, DEF_STR(On) ) // 有り + PORT_DIPNAME( 0x40, 0x40, DEF_STR(Flip_Screen) ) PORT_DIPLOCATION("SW1:7") // 画面反転 + PORT_DIPSETTING( 0x40, DEF_STR(Off) ) // 正 + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // 逆 + PORT_DIPNAME( 0x80, 0x80, DEF_STR(Service_Mode) ) PORT_DIPLOCATION("SW1:8") // モード + PORT_DIPSETTING( 0x80, DEF_STR(Off) ) // ゲームモード + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // テストモード PORT_START("DSW1") // IN11 - DSW1 - PORT_DIPUNUSED_DIPLOC( 0x01, 0x01, "SW2:1" ) - PORT_DIPUNUSED_DIPLOC( 0x02, 0x02, "SW2:2" ) - PORT_DIPUNUSED_DIPLOC( 0x04, 0x04, "SW2:3" ) - PORT_DIPUNUSED_DIPLOC( 0x08, 0x08, "SW2:4" ) - PORT_DIPUNUSED_DIPLOC( 0x10, 0x10, "SW2:5" ) - PORT_DIPUNUSED_DIPLOC( 0x20, 0x20, "SW2:6" ) - PORT_DIPUNUSED_DIPLOC( 0x40, 0x40, "SW2:7" ) - PORT_DIPUNUSED_DIPLOC( 0x80, 0x80, "SW2:8" ) + PORT_DIPUNKNOWN_DIPLOC( 0x01, 0x00, "SW2:1" ) // 常時OFF (manual appears to be corrected to indicate that this switch should be ON) + PORT_DIPUNKNOWN_DIPLOC( 0x02, 0x02, "SW2:2" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x04, 0x04, "SW2:3" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x08, 0x08, "SW2:4" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x10, 0x10, "SW2:5" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x20, 0x20, "SW2:6" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x40, 0x40, "SW2:7" ) // 常時OFF + PORT_DIPUNKNOWN_DIPLOC( 0x80, 0x80, "SW2:8" ) // 常時OFF INPUT_PORTS_END static INPUT_PORTS_START( hparadis ) diff --git a/src/mame/dynax/dynax.cpp b/src/mame/dynax/dynax.cpp index 99263bafe88..d76a247c7ed 100644 --- a/src/mame/dynax/dynax.cpp +++ b/src/mame/dynax/dynax.cpp @@ -2182,55 +2182,55 @@ INPUT_PORTS_END static INPUT_PORTS_START( mjdialq2 ) PORT_START("DSW0") - PORT_DIPNAME( 0x03, 0x03, DEF_STR( Coinage ) ) PORT_DIPLOCATION("SW1:1,2") - PORT_DIPSETTING( 0x00, DEF_STR( 3C_1C ) ) - PORT_DIPSETTING( 0x02, DEF_STR( 2C_1C ) ) - PORT_DIPSETTING( 0x03, DEF_STR( 1C_1C ) ) - PORT_DIPSETTING( 0x01, DEF_STR( 1C_2C ) ) - PORT_DIPNAME( 0x04, 0x00, "PINFU with TSUMO" ) PORT_DIPLOCATION("SW1:3") - PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) - PORT_DIPNAME( 0x38, 0x20, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:4,5,6") - PORT_DIPSETTING( 0x38, "1 (Easy)" ) - PORT_DIPSETTING( 0x30, "2" ) - PORT_DIPSETTING( 0x28, "3" ) - PORT_DIPSETTING( 0x20, "4" ) - PORT_DIPSETTING( 0x18, "5" ) - PORT_DIPSETTING( 0x10, "6" ) - PORT_DIPSETTING( 0x08, "7" ) - PORT_DIPSETTING( 0x00, "8 (Hard)" ) - PORT_DIPNAME( 0x40, 0x00, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION("SW1:7") - PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x80, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION("SW1:8") - PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) + PORT_DIPNAME( 0x03, 0x03, DEF_STR(Coinage ) ) PORT_DIPLOCATION("SW. 1:1,2") // プレイ料金 + PORT_DIPSETTING( 0x00, DEF_STR(3C_1C) ) // 3コイン 1プレー + PORT_DIPSETTING( 0x02, DEF_STR(2C_1C) ) // 2コイン 1プレー + PORT_DIPSETTING( 0x03, DEF_STR(1C_1C) ) // 1コイン 1プレー + PORT_DIPSETTING( 0x01, DEF_STR(1C_2C) ) // 1コイン 2プレー + PORT_DIPNAME( 0x04, 0x00, "Allow Pinfu with Tsumo") PORT_DIPLOCATION("SW. 1:3") // ルール ピンフ・ツモ複合 + PORT_DIPSETTING( 0x04, DEF_STR(No) ) // 無し + PORT_DIPSETTING( 0x00, DEF_STR(Yes) ) // 有り + PORT_DIPNAME( 0x38, 0x20, DEF_STR(Difficulty) ) PORT_DIPLOCATION("SW. 1:4,5,6") // 難易度 コンピュー + PORT_DIPSETTING( 0x38, "1 (Weak)" ) // 弱い  (1) + PORT_DIPSETTING( 0x30, "2" ) //     (2) + PORT_DIPSETTING( 0x28, "3" ) //     (3) + PORT_DIPSETTING( 0x20, "4 (Normal)" ) // 標準  (4) + PORT_DIPSETTING( 0x18, "5" ) //     (5) + PORT_DIPSETTING( 0x10, "6" ) //     (6) + PORT_DIPSETTING( 0x08, "7" ) //     (7) + PORT_DIPSETTING( 0x00, "8 (Strong)" ) // 強い  (8) + PORT_DIPNAME( 0x40, 0x00, DEF_STR(Demo_Sounds ) ) PORT_DIPLOCATION("SW. 1:7") // デモ・サウンド + PORT_DIPSETTING( 0x40, DEF_STR(Off) ) // 無し + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // 有り + PORT_DIPNAME( 0x80, 0x80, DEF_STR(Flip_Screen) ) PORT_DIPLOCATION("SW. 1:8") // モニター画面反転 + PORT_DIPSETTING( 0x80, DEF_STR(Off) ) // 正 + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // 逆 PORT_START("DSW1") - PORT_DIPNAME( 0x07, 0x07, "Time Setting" ) PORT_DIPLOCATION("SW2:1,2,3") - PORT_DIPSETTING( 0x07, "08:30" ) - PORT_DIPSETTING( 0x06, "09:00" ) - PORT_DIPSETTING( 0x05, "09:30" ) - PORT_DIPSETTING( 0x04, "10:00" ) - PORT_DIPSETTING( 0x03, "10:30" ) - PORT_DIPSETTING( 0x02, "11:00" ) - PORT_DIPSETTING( 0x01, "11:30" ) - PORT_DIPSETTING( 0x00, "12:00" ) - PORT_DIPNAME( 0x08, 0x00, "Time Service" ) PORT_DIPLOCATION("SW2:4") // "secret moves" happen at certain time stamps - PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) - PORT_DIPNAME( 0x10, 0x10, "TEL Display" ) PORT_DIPLOCATION("SW2:5") - PORT_DIPSETTING( 0x10, DEF_STR( On ) ) - PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) - PORT_DIPNAME( 0x20, 0x20, "GAL mode" ) PORT_DIPLOCATION("SW2:6") // unknown what this does - PORT_DIPSETTING( 0x20, "1" ) - PORT_DIPSETTING( 0x00, "2" ) - PORT_DIPNAME( 0x40, 0x40, "Select Special Item" ) PORT_DIPLOCATION("SW2:7")/* Allows to select which one of the nine special items you want. */ - PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) - PORT_DIPNAME( 0x80, 0x80, "Debug" ) PORT_DIPLOCATION("SW2:8") - PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) - PORT_DIPSETTING( 0x00, DEF_STR( On ) ) + PORT_DIPNAME( 0x07, 0x07, "Game Clock Start" ) PORT_DIPLOCATION("SW. 2:1,2,3") // ゲーム時計スタート + PORT_DIPSETTING( 0x07, "08:30" ) //  8時30分 + PORT_DIPSETTING( 0x06, "09:00" ) //  9時00分 + PORT_DIPSETTING( 0x05, "09:30" ) //  9時30分 + PORT_DIPSETTING( 0x04, "10:00" ) // 10時00分 + PORT_DIPSETTING( 0x03, "10:30" ) // 10時30分 + PORT_DIPSETTING( 0x02, "11:00" ) // 11時00分 + PORT_DIPSETTING( 0x01, "11:30" ) // 11時30分 + PORT_DIPSETTING( 0x00, "12:00" ) // 12時00分 + PORT_DIPNAME( 0x08, 0x00, "Time Service" ) PORT_DIPLOCATION("SW. 2:4") // タイム-サービス(時間等によりできる秘技) + PORT_DIPSETTING( 0x08, DEF_STR(Off) ) // 無し + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // 有り (allows secret techniques depending on the time) + PORT_DIPNAME( 0x10, 0x10, "Show Telephone Numbers" ) PORT_DIPLOCATION("SW. 2:5") // TEL表示 + PORT_DIPSETTING( 0x00, DEF_STR(Off) ) // 無し + PORT_DIPSETTING( 0x10, DEF_STR(On) ) // 有り + PORT_DIPNAME( 0x20, 0x20, "Gal Mode" ) PORT_DIPLOCATION("SW. 2:6") // GALモード切り替え (not clear what this does) + PORT_DIPSETTING( 0x20, "1" ) // 1 + PORT_DIPSETTING( 0x00, "2" ) // 2 + PORT_DIPNAME( 0x40, 0x40, "Bonus Item Select (cheat)" ) PORT_DIPLOCATION("SW. 2:7") // OFF固定 + PORT_DIPSETTING( 0x40, DEF_STR(Off) ) + PORT_DIPSETTING( 0x00, DEF_STR(On) ) // (allows you to select a bonus item and always win the jan-ken-pon game) + PORT_DIPNAME( 0x80, 0x80, "Show Debug Info" ) PORT_DIPLOCATION("SW. 2:8") // OFF固定 + PORT_DIPSETTING( 0x80, DEF_STR(Off) ) + PORT_DIPSETTING( 0x00, DEF_STR(On) ) PORT_START("COINS") PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // "17B" @@ -2242,7 +2242,7 @@ static INPUT_PORTS_START( mjdialq2 ) PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) // "18A" - PORT_INCLUDE( dynax_mahjong_keys ) + PORT_INCLUDE( mahjong_matrix_2p_ff ) INPUT_PORTS_END @@ -2353,7 +2353,7 @@ static INPUT_PORTS_START( mjcomv1 ) PORT_START("COINS") PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) // "17B" PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) // "18B" - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME(DEF_STR(Test)) + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_TOGGLE PORT_NAME(DEF_STR(Test)) PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_GAMBLE_BOOK ) // Analyzer PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_MEMORY_RESET ) // Memory Reset PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN ) // "06B" @@ -3355,7 +3355,7 @@ static INPUT_PORTS_START( neruton ) PORT_DIPSETTING( 0x02, "11:00" ) // 11時00分 PORT_DIPSETTING( 0x01, "11:30" ) // 11時30分 PORT_DIPSETTING( 0x00, "12:00" ) // 12時00分 - PORT_DIPNAME( 0x08, 0x00, "Time Service" ) PORT_DIPLOCATION("SW. 2:4") // タイム-サービス + PORT_DIPNAME( 0x08, 0x00, "Time Service" ) PORT_DIPLOCATION("SW. 2:4") // タイム-サービス(時間等によりできる秘技) PORT_DIPSETTING( 0x08, DEF_STR(Off) ) // 無し PORT_DIPSETTING( 0x00, DEF_STR(On) ) // 有り (allows secret techniques depending on the time) PORT_DIPNAME( 0x10, 0x10, "Gal H Pose" ) PORT_DIPLOCATION("SW. 2:5") // OFF固定 diff --git a/src/mame/shared/xbox_nv2a.cpp b/src/mame/shared/xbox_nv2a.cpp index eafbb674a72..f7917dd53ce 100644 --- a/src/mame/shared/xbox_nv2a.cpp +++ b/src/mame/shared/xbox_nv2a.cpp @@ -1,9 +1,12 @@ // license:BSD-3-Clause // copyright-holders:Samuele Zannoli #include "emu.h" -#include "bitmap.h" -#include "video/rgbutil.h" #include "xbox_nv2a.h" + +#include "video/rgbutil.h" + +#include "bitmap.h" + #include #include -- cgit v1.2.3