mirror of
https://github.com/holub/mame
synced 2025-04-21 16:01:56 +03:00
Tidy some recent changes.
This commit is contained in:
parent
3c2e6aa2e5
commit
052d4facce
@ -12,6 +12,8 @@
|
||||
#include "emu.h"
|
||||
#include "fuukitmap.h"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
|
||||
void fuukitmap_device::vram_map(address_map &map)
|
||||
{
|
||||
@ -46,6 +48,7 @@ fuukitmap_device::fuukitmap_device(const machine_config &mconfig, const char *ta
|
||||
, m_layer2_xoffs(0)
|
||||
, m_layer2_yoffs(0)
|
||||
, m_tilemap{ nullptr, nullptr, nullptr }
|
||||
, m_vram(*this, "vram%u", 0U, 0x2000U, ENDIANNESS_BIG)
|
||||
, m_unknown{ 0, 0 }
|
||||
, m_priority(0)
|
||||
, m_flip(false)
|
||||
@ -62,14 +65,7 @@ void fuukitmap_device::device_start()
|
||||
{
|
||||
m_colour_cb.resolve();
|
||||
|
||||
for (int i = 0; i < 4; i++)
|
||||
{
|
||||
m_vram[i] = make_unique_clear<u16 []>(0x2000 / 2);
|
||||
|
||||
save_pointer(NAME(m_vram[i]), 0x2000 / 2, i);
|
||||
}
|
||||
|
||||
m_vregs = make_unique_clear<u16 []>(0x20 / 2);
|
||||
std::fill(std::begin(m_vregs), std::end(m_vregs), 0);
|
||||
|
||||
m_tilemap[0] = &machine().tilemap().create(*this, tilemap_get_info_delegate(*this, FUNC(fuukitmap_device::get_tile_info<0>)), TILEMAP_SCAN_ROWS, 16, 16, 64, 32);
|
||||
m_tilemap[1] = &machine().tilemap().create(*this, tilemap_get_info_delegate(*this, FUNC(fuukitmap_device::get_tile_info<1>)), TILEMAP_SCAN_ROWS, 16, 16, 64, 32);
|
||||
@ -79,7 +75,7 @@ void fuukitmap_device::device_start()
|
||||
m_vblank_interrupt_timer = timer_alloc(FUNC(fuukitmap_device::vblank_interrupt), this);
|
||||
m_raster_interrupt_timer = timer_alloc(FUNC(fuukitmap_device::raster_interrupt), this);
|
||||
|
||||
save_pointer(NAME(m_vregs), 0x20 / 2);
|
||||
save_item(NAME(m_vregs));
|
||||
save_item(NAME(m_unknown));
|
||||
save_item(NAME(m_priority));
|
||||
save_item(NAME(m_flip));
|
||||
|
@ -76,10 +76,10 @@ private:
|
||||
int m_layer2_yoffs;
|
||||
|
||||
// video-related
|
||||
tilemap_t *m_tilemap[3]{};
|
||||
tilemap_t *m_tilemap[3];
|
||||
|
||||
std::unique_ptr<u16[]> m_vram[4];
|
||||
std::unique_ptr<u16[]> m_vregs;
|
||||
memory_share_array_creator<u16, 4> m_vram;
|
||||
u16 m_vregs[0x20 / 2];
|
||||
u16 m_unknown[2];
|
||||
u16 m_priority;
|
||||
|
||||
|
@ -565,9 +565,9 @@ u16 m72_state::protection_r(offs_t offset, u16 mem_mask)
|
||||
if (ACCESSING_BITS_8_15)
|
||||
{
|
||||
if (!machine().side_effects_disabled())
|
||||
copy_le(m_protection_ram.get(),m_protection_code,CODE_LEN);
|
||||
copy_le(m_protection_ram.get(), m_protection_code, CODE_LEN);
|
||||
}
|
||||
return m_protection_ram[0xffa/2+offset];
|
||||
return m_protection_ram[0xffa/2 + offset];
|
||||
}
|
||||
|
||||
void m72_state::protection_w(offs_t offset, u16 data, u16 mem_mask)
|
||||
|
@ -330,13 +330,13 @@ void m72_state::port02_w(u8 data)
|
||||
machine().bookkeeping().coin_counter_w(1, BIT(data, 1));
|
||||
|
||||
/* bit 2 is flip screen (handled both by software and hardware) */
|
||||
flip_screen_set(BIT(data, 2) ^ ((~m_io_dsw->read() >> 8) & 1));
|
||||
flip_screen_set(BIT(data, 2) ^ BIT(~m_io_dsw->read(), 8));
|
||||
|
||||
/* bit 3 is display disable */
|
||||
m_video_off = BIT(data, 3);
|
||||
|
||||
/* bit 4 resets sound CPU (active low) */
|
||||
if (data & 0x10)
|
||||
if (BIT(data, 4))
|
||||
m_soundcpu->set_input_line(INPUT_LINE_RESET, CLEAR_LINE);
|
||||
else
|
||||
m_soundcpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE);
|
||||
|
@ -10978,6 +10978,8 @@ ROM_START( falcnwldd ) // "831 1.1 MADE IN JAPAN" without extra MCU
|
||||
ROM_LOAD( "falcon_1.bin", 0x0000, 0x0100, CRC(3db3b9e0) SHA1(c956493d5d754665d214b416e6a473d73c22716c) )
|
||||
ROM_END
|
||||
|
||||
|
||||
|
||||
/**************************************** OTHER SETS ****************************************/
|
||||
|
||||
|
||||
|
@ -7,11 +7,11 @@
|
||||
The CPU is identified on schematics as a custom "90435" type, but
|
||||
board photos confirm it really is a CDP1802ACE as the pinout
|
||||
and support ICs suggest. Its XTAL value is specified as 2.95 MHz,
|
||||
but 3 MHZ has also been seen on one set of Night Mare.
|
||||
but 3 MHz has also been seen on one set of Night Mare.
|
||||
|
||||
The synthesizer IC is custom-marked as EFO90503, but it also bears
|
||||
a TI logo and is obviously some sort of TMS5220 variant. Its
|
||||
discrete oscillator circuit is tuned for a 160 KHz operating
|
||||
discrete oscillator circuit is tuned for a 160 kHz operating
|
||||
frequency, according to both schematics and board markings.
|
||||
(Unlike other EFO sound boards, Sound-3 has no PSG.)
|
||||
|
||||
|
@ -131,7 +131,7 @@ INPUT_PORTS_START(byte)
|
||||
|
||||
PORT_START("IO_LINE0") /* 0xFEFE */
|
||||
PORT_BIT(0x000001, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"ПРОПИСНЫЕ") PORT_CODE(KEYCODE_LSHIFT) PORT_CHAR(UCHAR_SHIFT_1)
|
||||
PORT_CODE(KEYCODE_RSHIFT) PORT_CHAR(UCHAR_SHIFT_2)
|
||||
PORT_CODE(KEYCODE_RSHIFT) PORT_CHAR(UCHAR_SHIFT_2)
|
||||
PORT_BIT(0x000002, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"Я Z :") PORT_CODE(KEYCODE_Z) PORT_CHAR('z') PORT_CHAR('Z') PORT_CHAR(':')
|
||||
PORT_BIT(0x020000, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("(SS+Z) :") PORT_CODE(KEYCODE_LALT)
|
||||
PORT_BIT(0x000004, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"Ч X $") PORT_CODE(KEYCODE_X) PORT_CHAR('x') PORT_CHAR('X') PORT_CHAR('$')
|
||||
@ -168,7 +168,7 @@ INPUT_PORTS_START(byte)
|
||||
PORT_BIT(0x000008, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4 $") PORT_CODE(KEYCODE_4) PORT_CHAR('4') PORT_CHAR('$')
|
||||
PORT_BIT(0x000800, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+4) НЕГАТ") PORT_CODE(KEYCODE_END)
|
||||
PORT_BIT(0x000010, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5 %") PORT_CODE(KEYCODE_5) PORT_CHAR('5') PORT_CHAR(UCHAR_MAMEKEY(LEFT)) PORT_CHAR('%')
|
||||
PORT_BIT(0x001000, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+5) ←") PORT_CODE(KEYCODE_LEFT)
|
||||
PORT_BIT(0x001000, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+5) \u2190") PORT_CODE(KEYCODE_LEFT) // ←
|
||||
PORT_BIT(0xffe0e0, IP_ACTIVE_LOW, IPT_UNUSED)
|
||||
|
||||
PORT_START("IO_LINE4") /* 0xEFFE */
|
||||
@ -177,11 +177,11 @@ INPUT_PORTS_START(byte)
|
||||
PORT_BIT(0x000002, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9 )") PORT_CODE(KEYCODE_9) PORT_CHAR('9') PORT_CHAR(')')
|
||||
PORT_BIT(0x000200, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+9) ГРАФ") PORT_CODE(KEYCODE_TILDE)
|
||||
PORT_BIT(0x000004, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8 (") PORT_CODE(KEYCODE_8) PORT_CHAR('8') PORT_CHAR(UCHAR_MAMEKEY(RIGHT)) PORT_CHAR('(')
|
||||
PORT_BIT(0x000400, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+8) →") PORT_CODE(KEYCODE_RIGHT)
|
||||
PORT_BIT(0x000400, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+8) \u2192") PORT_CODE(KEYCODE_RIGHT) // →
|
||||
PORT_BIT(0x000008, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7 '") PORT_CODE(KEYCODE_7) PORT_CHAR('7') PORT_CHAR(UCHAR_MAMEKEY(UP)) PORT_CHAR('\'')
|
||||
PORT_BIT(0x000800, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+7) ↑") PORT_CODE(KEYCODE_UP)
|
||||
PORT_BIT(0x000800, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+7) \u2191") PORT_CODE(KEYCODE_UP) // ↑
|
||||
PORT_BIT(0x000010, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6 &") PORT_CODE(KEYCODE_6) PORT_CHAR('6') PORT_CHAR(UCHAR_MAMEKEY(DOWN)) PORT_CHAR('&')
|
||||
PORT_BIT(0x001000, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+6) ↓") PORT_CODE(KEYCODE_DOWN)
|
||||
PORT_BIT(0x001000, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"(CS+6) \u2193") PORT_CODE(KEYCODE_DOWN) // ↓
|
||||
PORT_BIT(0x000020, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"РУС") PORT_CODE(KEYCODE_BACKSLASH)
|
||||
PORT_BIT(0x000080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"Ъ ПФ2") PORT_CODE(KEYCODE_CLOSEBRACE)
|
||||
PORT_BIT(0xffe040, IP_ACTIVE_LOW, IPT_UNUSED)
|
||||
@ -210,7 +210,7 @@ INPUT_PORTS_START(byte)
|
||||
PORT_BIT(0x000001, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"ПРОБЕЛ") PORT_CODE(KEYCODE_SPACE) PORT_CHAR(' ')
|
||||
PORT_BIT(0x000100, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"ОСТАНОВ") PORT_CODE(KEYCODE_BACKSPACE)
|
||||
PORT_BIT(0x000002, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"РЕГ1") PORT_CODE(KEYCODE_LCONTROL) PORT_CHAR(UCHAR_MAMEKEY(LCONTROL))
|
||||
PORT_CODE(KEYCODE_RCONTROL) PORT_CHAR(UCHAR_MAMEKEY(RCONTROL))
|
||||
PORT_CODE(KEYCODE_RCONTROL) PORT_CHAR(UCHAR_MAMEKEY(RCONTROL))
|
||||
PORT_BIT(0x000200, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"РЕГ2") PORT_CODE(KEYCODE_CAPSLOCK)
|
||||
PORT_BIT(0x000004, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"Ь M .") PORT_CODE(KEYCODE_M) PORT_CHAR('m') PORT_CHAR('M') PORT_CHAR('.')
|
||||
PORT_BIT(0x000008, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(u8"Т N ,") PORT_CODE(KEYCODE_N) PORT_CHAR('n') PORT_CHAR('N') PORT_CHAR(',')
|
||||
|
Loading…
Reference in New Issue
Block a user