mirror of
https://github.com/holub/mame
synced 2025-10-04 16:34:53 +03:00
srcclean and manual cleanups (nw)
please people, remember to keep source UTF-8 and if you're committing on behalf of others, clean up indents to meet MAME conventions anyone can run srcclean over a submission and see what will get hit
This commit is contained in:
parent
ef82d89e3a
commit
25f84e3bf0
@ -1370,7 +1370,6 @@ files {
|
||||
MAME_DIR .. "src/mame/machine/apricotkb.cpp",
|
||||
MAME_DIR .. "src/mame/machine/apricotkb.h",
|
||||
MAME_DIR .. "src/mame/drivers/victor9k.cpp",
|
||||
-- MAME_DIR .. "src/mame/includes/victor9k.h",
|
||||
MAME_DIR .. "src/mame/machine/victor9k_kb.cpp",
|
||||
MAME_DIR .. "src/mame/machine/victor9k_kb.h",
|
||||
MAME_DIR .. "src/mame/machine/victor9k_fdc.cpp",
|
||||
|
@ -8,11 +8,11 @@
|
||||
/*
|
||||
* This card is part of Matsushita MyBrain 3000 and branded Panasonic JB-3000
|
||||
* and Ericsson Step/One computers. These are not really PC compatibles but
|
||||
* mimics the IBM PC in feature set and stays close on hardware but not 100%
|
||||
* mimic the IBM PC in feature set and stay close on hardware but not 100%
|
||||
*
|
||||
* Serial connector from Step/One service manual
|
||||
* ---------------------------------------------
|
||||
* Pin numbering------====------------------+ 1 - FG (AA) Chassi GND
|
||||
* Pin numbering------====------------------+ 1 - FG (AA) Chassis GND
|
||||
* | 25 23 21 19 17 15 13 11 9 7 5 3 1 | 3 - SD (BA) TxD
|
||||
* | 26 24 22 20 18 16 14 12 10 8 6 4 2 | 4 - ST (DB) TxC
|
||||
* +----------------------------------------+ 5 - RD (BB) RxD
|
||||
|
@ -2,7 +2,7 @@
|
||||
// copyright-holders:Fredrik Öhrström
|
||||
/**********************************************************************
|
||||
|
||||
myb3k_kbd.h
|
||||
myb3k_kbd.cpp
|
||||
|
||||
Matsushita My Brain 3000 -- Panasonic JB-3000 -- Ericsson Step/One
|
||||
keyboard emulation.
|
||||
@ -288,9 +288,7 @@ myb3k_keyboard_device::myb3k_keyboard_device(
|
||||
u32 clock)
|
||||
: device_t(mconfig, type, tag, owner, clock)
|
||||
, m_keyboard_cb()
|
||||
, m_io_kbd_t{ {*this, "MYB3K_T0"}, {*this, "MYB3K_T1"}, {*this, "MYB3K_T2"}, {*this, "MYB3K_T3"},
|
||||
{*this, "MYB3K_T4"}, {*this, "MYB3K_T5"}, {*this, "MYB3K_T6"}, {*this, "MYB3K_T7"},
|
||||
{*this, "MYB3K_T8"}, {*this, "MYB3K_T9"}, {*this, "MYB3K_TA"}, {*this, "MYB3K_TB"} }
|
||||
, m_io_kbd_t(*this, "MYB3K_T%X", 0U)
|
||||
{
|
||||
}
|
||||
|
||||
@ -349,7 +347,7 @@ void myb3k_keyboard_device::scan_keys()
|
||||
// and for each column iterate over all rows (m_y)
|
||||
bool wait_for_timer = false;
|
||||
while (!wait_for_timer) {
|
||||
ioport_value bit = 0x01 & (m_io_kbd_t[m_x]->read() >> m_y);
|
||||
ioport_value bit = BIT(m_io_kbd_t[m_x]->read(), m_y);
|
||||
ioport_value bit_toggled = bit ^ m_io_kbd_state[m_x][m_y];
|
||||
|
||||
if (bit_toggled) {
|
||||
|
@ -1,5 +1,5 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Fredrik Öhrström
|
||||
// copyright-holders:Fredrik Öhrström
|
||||
/**********************************************************************
|
||||
|
||||
myb3k_kbd.h
|
||||
@ -75,7 +75,7 @@ protected:
|
||||
private:
|
||||
|
||||
output_delegate m_keyboard_cb;
|
||||
required_ioport m_io_kbd_t[12];
|
||||
required_ioport_array<12> m_io_kbd_t;
|
||||
u8 m_io_kbd_state[12][8];
|
||||
|
||||
int m_x, m_y;
|
||||
|
@ -95,11 +95,10 @@ public:
|
||||
m_vram(*this, "vram"),
|
||||
m_gfx(*this, "gfx"),
|
||||
m_ram(*this, "ram")
|
||||
|
||||
{ }
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
|
||||
public:
|
||||
|
||||
DECLARE_READ_LINE_MEMBER(kbd_matrix_r);
|
||||
DECLARE_WRITE8_MEMBER(kbd_matrix_w);
|
||||
DECLARE_READ8_MEMBER(kbd_port2_r);
|
||||
@ -119,6 +118,7 @@ public:
|
||||
protected:
|
||||
virtual void machine_start() override;
|
||||
virtual void machine_reset() override;
|
||||
|
||||
required_device<address_map_bank_device> m_bankdev;
|
||||
required_device<i8041_device> m_kbdmcu;
|
||||
required_device<crt5037_device> m_crtc;
|
||||
@ -129,7 +129,6 @@ protected:
|
||||
required_ioport_array<16> m_keycols;
|
||||
|
||||
private:
|
||||
|
||||
uint8_t m_kbdclk, m_kbdread, m_kbdport2;
|
||||
required_device<palette_device> m_palette;
|
||||
required_shared_ptr<u8> m_vram;
|
||||
@ -137,8 +136,6 @@ private:
|
||||
required_shared_ptr<u8> m_ram;
|
||||
floppy_image_device *m_curfloppy;
|
||||
bool m_fdc_irq, m_fdc_drq, m_fdc_hld;
|
||||
floppy_connector *m_con1, *m_con2;
|
||||
|
||||
};
|
||||
|
||||
|
||||
@ -492,8 +489,8 @@ WRITE_LINE_MEMBER(alphatpx_state::fdchld_w)
|
||||
READ8_MEMBER(alphatpx_state::fdc_stat_r)
|
||||
{
|
||||
uint8_t res = 0;
|
||||
floppy_image_device *floppy1 = m_con1 ? m_con1->get_device() : nullptr;
|
||||
floppy_image_device *floppy2 = m_con2 ? m_con2->get_device() : nullptr;
|
||||
floppy_image_device *floppy1 = m_floppy0->get_device();
|
||||
floppy_image_device *floppy2 = m_floppy1->get_device();
|
||||
|
||||
res = m_fdc_drq ? 0x80 : 0x00;
|
||||
res |= m_fdc_irq ? 0x40 : 0x00;
|
||||
@ -534,13 +531,9 @@ WRITE8_MEMBER(alphatpx_state::fdc_cmd_w)
|
||||
|
||||
// select drive
|
||||
if (!(data & 0x80))
|
||||
{
|
||||
floppy = m_con1 ? m_con1->get_device() : nullptr;
|
||||
}
|
||||
floppy = m_floppy0->get_device();
|
||||
else if (!(data & 0x40))
|
||||
{
|
||||
floppy = m_con2 ? m_con2->get_device() : nullptr;
|
||||
}
|
||||
floppy = m_floppy1->get_device();
|
||||
|
||||
// selecting a new drive?
|
||||
if (floppy != m_curfloppy)
|
||||
@ -589,10 +582,6 @@ void alphatpx_state::machine_reset()
|
||||
m_kbdread = 1;
|
||||
m_kbdclk = 1; m_fdc_irq = m_fdc_drq = m_fdc_hld = 0;
|
||||
m_curfloppy = nullptr;
|
||||
|
||||
// look up floppies in advance
|
||||
m_con1 = machine().device<floppy_connector>("fdc:0");
|
||||
m_con2 = machine().device<floppy_connector>("fdc:1");
|
||||
}
|
||||
|
||||
//**************************************************************************
|
||||
|
@ -2443,18 +2443,18 @@ static INPUT_PORTS_START( towns )
|
||||
PORT_BIT(0x08000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("@ ` \xE2\x80\x9D") PORT_CODE(KEYCODE_OPENBRACE) PORT_CHAR('@')
|
||||
PORT_BIT(0x10000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("[ { \xE3\x82\x9C \xE3\x80\x8C") PORT_CODE(KEYCODE_CLOSEBRACE) PORT_CHAR('[')
|
||||
PORT_BIT(0x20000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("RETURN") PORT_CODE(KEYCODE_ENTER) PORT_CHAR(27)
|
||||
PORT_BIT(0x40000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("A \xE3\x81\xA1") PORT_CODE(KEYCODE_A) PORT_CHAR('A')
|
||||
PORT_BIT(0x80000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("S \xE3\x81\xA8") PORT_CODE(KEYCODE_S) PORT_CHAR('S')
|
||||
PORT_BIT(0x40000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("A?\xE3\x81\xA1") PORT_CODE(KEYCODE_A) PORT_CHAR('A')
|
||||
PORT_BIT(0x80000000,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("S?\xE3\x81\xA8") PORT_CODE(KEYCODE_S) PORT_CHAR('S')
|
||||
|
||||
PORT_START( "key2" ) // scancodes 0x20-0x3f
|
||||
PORT_BIT(0x00000001,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("D \xE3\x81\x97") PORT_CODE(KEYCODE_D) PORT_CHAR('D')
|
||||
PORT_BIT(0x00000002,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("F \xE3\x81\xAF") PORT_CODE(KEYCODE_F) PORT_CHAR('F')
|
||||
PORT_BIT(0x00000004,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("G \xE3\x81\x8D") PORT_CODE(KEYCODE_G) PORT_CHAR('G')
|
||||
PORT_BIT(0x00000008,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("H \xE3\x81\x8F") PORT_CODE(KEYCODE_H) PORT_CHAR('H')
|
||||
PORT_BIT(0x00000010,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("J \xE3\x81\xBE") PORT_CODE(KEYCODE_J) PORT_CHAR('J')
|
||||
PORT_BIT(0x00000020,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("K \xE3\x81\xAE") PORT_CODE(KEYCODE_K) PORT_CHAR('K')
|
||||
PORT_BIT(0x00000040,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("L \xE3\x82\x8A") PORT_CODE(KEYCODE_L) PORT_CHAR('L')
|
||||
PORT_BIT(0x00000080,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("; + \xE3\x82\x8C") PORT_CODE(KEYCODE_COLON) PORT_CHAR(';')
|
||||
PORT_BIT(0x00000001,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("D?\xE3\x81\x97") PORT_CODE(KEYCODE_D) PORT_CHAR('D')
|
||||
PORT_BIT(0x00000002,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("F?\xE3\x81\xAF") PORT_CODE(KEYCODE_F) PORT_CHAR('F')
|
||||
PORT_BIT(0x00000004,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("G?\xE3\x81\x8D") PORT_CODE(KEYCODE_G) PORT_CHAR('G')
|
||||
PORT_BIT(0x00000008,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("H?\xE3\x81\x8F") PORT_CODE(KEYCODE_H) PORT_CHAR('H')
|
||||
PORT_BIT(0x00000010,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("J?\xE3\x81\xBE") PORT_CODE(KEYCODE_J) PORT_CHAR('J')
|
||||
PORT_BIT(0x00000020,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("K?\xE3\x81\xAE") PORT_CODE(KEYCODE_K) PORT_CHAR('K')
|
||||
PORT_BIT(0x00000040,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("L?\xE3\x82\x8A") PORT_CODE(KEYCODE_L) PORT_CHAR('L')
|
||||
PORT_BIT(0x00000080,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME(";?+ \xE3\x82\x8C") PORT_CODE(KEYCODE_COLON) PORT_CHAR(';')
|
||||
PORT_BIT(0x00000100,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME(": * \xE3\x81\x91") PORT_CODE(KEYCODE_QUOTE) PORT_CHAR(':')
|
||||
PORT_BIT(0x00000200,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("] } \xE3\x82\x80 \xE3\x80\x8D") PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR(']')
|
||||
PORT_BIT(0x00000400,IP_ACTIVE_HIGH,IPT_KEYBOARD) PORT_NAME("Z \xE3\x81\xA4 \xE3\x81\xA3") PORT_CODE(KEYCODE_Z) PORT_CHAR('Z')
|
||||
|
@ -5,7 +5,7 @@
|
||||
pgm2_memcard.cpp
|
||||
|
||||
PGM2 Memory card functions.
|
||||
Presumable Siemens SLE 4442 or compatible.
|
||||
Presumably Siemens SLE 4442 or compatible.
|
||||
|
||||
*********************************************************************/
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user