diff options
| author | 2015-04-29 08:18:54 +0200 | |
|---|---|---|
| committer | 2015-04-29 08:18:54 +0200 | |
| commit | 76b978d039f922ed84796deb999389ebb1579191 (patch) | |
| tree | 90e4fe3efe7a18b896e49fd7fb65ba7a144cac0f /src/emu | |
| parent | 64219f27d20c0f6f2dc8c168c8c19ba9420f889d (diff) | |
Cleanups and version bumpmame0161
Diffstat (limited to 'src/emu')
74 files changed, 382 insertions, 397 deletions
diff --git a/src/emu/bus/a800/a800_slot.c b/src/emu/bus/a800/a800_slot.c index adbe023271a..028fa02b2a0 100644 --- a/src/emu/bus/a800/a800_slot.c +++ b/src/emu/bus/a800/a800_slot.c @@ -62,7 +62,7 @@ device_a800_cart_interface::~device_a800_cart_interface () void device_a800_cart_interface::rom_alloc(UINT32 size, const char *tag) { if (m_rom == NULL) - { + { m_rom = device().machine().memory().region_alloc(std::string(tag).append(A800SLOT_ROM_REGION_TAG).c_str(), size, 1, ENDIANNESS_LITTLE)->base(); m_rom_size = size; diff --git a/src/emu/bus/abcbus/abc890.h b/src/emu/bus/abcbus/abc890.h index 0bc29b02ad7..3d808ec5a28 100644 --- a/src/emu/bus/abcbus/abc890.h +++ b/src/emu/bus/abcbus/abc890.h @@ -26,7 +26,7 @@ // ======================> abc890_t class abc890_t : public device_t, - public device_abcbus_card_interface + public device_abcbus_card_interface { public: // construction/destruction diff --git a/src/emu/bus/abcbus/fd2.c b/src/emu/bus/abcbus/fd2.c index a792b0d88ab..0d5d8c3d93b 100644 --- a/src/emu/bus/abcbus/fd2.c +++ b/src/emu/bus/abcbus/fd2.c @@ -100,7 +100,7 @@ WRITE8_MEMBER( abc_fd2_t::status_w ) 3 4 5 - 6 + 6 7 */ @@ -154,11 +154,11 @@ READ8_MEMBER( abc_fd2_t::pio_pb_r ) bit description - 0 - 1 - 2 - 3 - 4 + 0 + 1 + 2 + 3 + 4 5 DRQ 6 HLD 7 INTRQ @@ -185,9 +185,9 @@ WRITE8_MEMBER( abc_fd2_t::pio_pb_w ) 2 TG43 3 MON 4 HLT - 5 - 6 - 7 + 5 + 6 + 7 */ diff --git a/src/emu/bus/abcbus/fd2.h b/src/emu/bus/abcbus/fd2.h index e41fa8d66e5..d0774818dbb 100644 --- a/src/emu/bus/abcbus/fd2.h +++ b/src/emu/bus/abcbus/fd2.h @@ -31,7 +31,7 @@ // ======================> abc_fd2_t class abc_fd2_t : public device_t, - public device_abcbus_card_interface + public device_abcbus_card_interface { public: // construction/destruction diff --git a/src/emu/bus/abcbus/lux4105.h b/src/emu/bus/abcbus/lux4105.h index 2615655272c..d00511a727b 100644 --- a/src/emu/bus/abcbus/lux4105.h +++ b/src/emu/bus/abcbus/lux4105.h @@ -36,7 +36,7 @@ // ======================> luxor_4105_device class luxor_4105_device : public device_t, - public device_abcbus_card_interface + public device_abcbus_card_interface { public: // construction/destruction diff --git a/src/emu/bus/abcbus/memcard.h b/src/emu/bus/abcbus/memcard.h index d7b9aac41b4..e901ac5050c 100644 --- a/src/emu/bus/abcbus/memcard.h +++ b/src/emu/bus/abcbus/memcard.h @@ -26,7 +26,7 @@ // ======================> abc_memory_card_t class abc_memory_card_t : public device_t, - public device_abcbus_card_interface + public device_abcbus_card_interface { public: // construction/destruction diff --git a/src/emu/bus/abcbus/ram.h b/src/emu/bus/abcbus/ram.h index 3f3a1efda72..64f3265422d 100644 --- a/src/emu/bus/abcbus/ram.h +++ b/src/emu/bus/abcbus/ram.h @@ -26,7 +26,7 @@ // ======================> abc80_16kb_ram_card_t class abc80_16kb_ram_card_t : public device_t, - public device_abcbus_card_interface + public device_abcbus_card_interface { public: // construction/destruction diff --git a/src/emu/bus/arcadia/slot.c b/src/emu/bus/arcadia/slot.c index 16b84601ac5..4d3d5e26012 100644 --- a/src/emu/bus/arcadia/slot.c +++ b/src/emu/bus/arcadia/slot.c @@ -48,7 +48,7 @@ device_arcadia_cart_interface::~device_arcadia_cart_interface() void device_arcadia_cart_interface::rom_alloc(UINT32 size, const char *tag) { if (m_rom == NULL) - { + { m_rom = device().machine().memory().region_alloc(std::string(tag).append(EA2001SLOT_ROM_REGION_TAG).c_str(), size, 1, ENDIANNESS_LITTLE)->base(); m_rom_size = size; } diff --git a/src/emu/bus/cbmiec/c1541.c b/src/emu/bus/cbmiec/c1541.c index ec5b2cb504d..94e594752f2 100644 --- a/src/emu/bus/cbmiec/c1541.c +++ b/src/emu/bus/cbmiec/c1541.c @@ -336,7 +336,7 @@ ROM_END const rom_entry *fsd1_device::device_rom_region() const { - return ROM_NAME( fsd1 ); + return ROM_NAME( fsd1 ); } @@ -353,8 +353,8 @@ ROM_START( fsd2 ) ROMX_LOAD( "fsd2b.u3", 0x0000, 0x4000, CRC(b39e4600) SHA1(991132fcc6e70e9a428062ae76055a150f2f7ac6), ROM_BIOS(2) ) ROM_SYSTEM_BIOS( 2, "jiffydos", "JiffyDOS v5.0" ) ROMX_LOAD( "jiffydos v5.0.u3", 0x0000, 0x4000, CRC(46c3302c) SHA1(e3623658cb7af30c9d3bce2ba3b6ad5ee89ac1b8), ROM_BIOS(3) ) - ROM_SYSTEM_BIOS( 3, "rexdos", "REX-DOS" ) - ROMX_LOAD( "rdos.bin", 0x0000, 0x4000, CRC(8ad6dba1) SHA1(f279d327d5e16ea1b62fb18514fb679d0b442941), ROM_BIOS(4) ) + ROM_SYSTEM_BIOS( 3, "rexdos", "REX-DOS" ) + ROMX_LOAD( "rdos.bin", 0x0000, 0x4000, CRC(8ad6dba1) SHA1(f279d327d5e16ea1b62fb18514fb679d0b442941), ROM_BIOS(4) ) ROM_END @@ -475,7 +475,7 @@ ROM_END const rom_entry *indus_gt_t::device_rom_region() const { - return ROM_NAME( indusgt ); + return ROM_NAME( indusgt ); } @@ -1064,7 +1064,7 @@ sx1541_device::sx1541_device(const machine_config &mconfig, const char *tag, dev //------------------------------------------------- fsd1_device::fsd1_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) - : base_c1541_device(mconfig, FSD1, "FSD-1", tag, owner, clock, "fsd1", __FILE__) { } + : base_c1541_device(mconfig, FSD1, "FSD-1", tag, owner, clock, "fsd1", __FILE__) { } //------------------------------------------------- diff --git a/src/emu/bus/gameboy/gb_slot.h b/src/emu/bus/gameboy/gb_slot.h index c04220323a4..61a7a7d8350 100644 --- a/src/emu/bus/gameboy/gb_slot.h +++ b/src/emu/bus/gameboy/gb_slot.h @@ -69,7 +69,7 @@ public: void rom_map_setup(UINT32 size); void ram_map_setup(UINT8 banks); - virtual void set_additional_wirings(UINT8 mask, int shift) { } // MBC-1 will then overwrite this! + virtual void set_additional_wirings(UINT8 mask, int shift) { } // MBC-1 will then overwrite this! void set_has_timer(bool val) { has_timer = val; } void set_has_rumble(bool val) { has_rumble = val; } void set_has_battery(bool val) { has_battery = val; } diff --git a/src/emu/bus/gameboy/mbc.c b/src/emu/bus/gameboy/mbc.c index a303910055e..9d1e5aef40e 100644 --- a/src/emu/bus/gameboy/mbc.c +++ b/src/emu/bus/gameboy/mbc.c @@ -25,7 +25,7 @@ const device_type GB_ROM_MBC7 = &device_creator<gb_rom_mbc7_device>; const device_type GB_ROM_M161_M12 = &device_creator<gb_rom_m161_device>; const device_type GB_ROM_MMM01 = &device_creator<gb_rom_mmm01_device>; const device_type GB_ROM_SACHEN1 = &device_creator<gb_rom_sachen1_device>; -const device_type GB_ROM_SACHEN2 = &device_creator<gb_rom_sachen1_device>; // Just a placeholder for the moment... +const device_type GB_ROM_SACHEN2 = &device_creator<gb_rom_sachen1_device>; // Just a placeholder for the moment... const device_type GB_ROM_188IN1 = &device_creator<gb_rom_188in1_device>; const device_type GB_ROM_SINTAX = &device_creator<gb_rom_sintax_device>; const device_type GB_ROM_CHONGWU = &device_creator<gb_rom_chongwu_device>; @@ -322,18 +322,18 @@ WRITE8_MEMBER(gb_rom_mbc1_device::write_bank) // the mapper only uses inputs A13-A15 switch (offset & 0xe000) { - case 0x0000: // RAM Enable Register + case 0x0000: // RAM Enable Register m_ram_enable = ((data & 0x0f) == 0x0a) ? 1 : 0; break; - case 0x2000: // ROM Bank Register + case 0x2000: // ROM Bank Register data &= 0x1f; m_latch_bank2 = data ? data : 1; m_latch_bank2 &= m_mask; break; - case 0x4000: // RAM Bank Register + case 0x4000: // RAM Bank Register m_ram_bank = data & 0x3; break; - case 0x6000: // MBC1 Mode Register + case 0x6000: // MBC1 Mode Register default: m_mode = (data & 0x1) ? MODE_4M_256k : MODE_16M_8k; break; @@ -647,10 +647,10 @@ WRITE8_MEMBER(gb_rom_m161_device::write_bank) { switch (offset & 0xe000) { - case 0x4000: // Base Bank Register + case 0x4000: // Base Bank Register m_base_bank = data << 1; break; - case 0x2000: // Tetris writes 1 here when selected... + case 0x2000: // Tetris writes 1 here when selected... default: break; } @@ -715,18 +715,18 @@ READ8_MEMBER(gb_rom_sachen1_device::read_rom) WRITE8_MEMBER(gb_rom_sachen1_device::write_bank) { - if (offset < 0x2000) // Base ROM Bank register + if (offset < 0x2000) // Base ROM Bank register { if ((m_latch_bank2 & 0x30) == 0x30 && data) m_base_bank = data & 0x0f; //logerror("write to base bank %X - %X\n", data, (m_base_bank & m_mask) | (m_latch_bank2 & ~m_mask)); } - else if (offset < 0x4000) // ROM Bank Register + else if (offset < 0x4000) // ROM Bank Register { m_latch_bank2 = data ? data : 1; //logerror("write to latch %X - %X\n", data, (m_base_bank & m_mask) | (m_latch_bank2 & ~m_mask)); } - else if (offset < 0x6000) // ROM bank mask register + else if (offset < 0x6000) // ROM bank mask register { if ((m_latch_bank2 & 0x30) == 0x30) m_mask = data; diff --git a/src/emu/bus/gameboy/mbc.h b/src/emu/bus/gameboy/mbc.h index bda06a65523..1d9e35c7ba9 100644 --- a/src/emu/bus/gameboy/mbc.h +++ b/src/emu/bus/gameboy/mbc.h @@ -33,12 +33,12 @@ public: class gb_rom_mbc1_device : public gb_rom_mbc_device { public: - + enum { MODE_16M_8k = 0, /// 16Mbit ROM, 8kBit RAM MODE_4M_256k = 1, /// 4Mbit ROM, 256kBit RAM }; - + // construction/destruction gb_rom_mbc1_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source); gb_rom_mbc1_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); @@ -46,7 +46,7 @@ public: // device-level overrides virtual void device_start() { shared_start(); save_item(NAME(m_mode)); }; virtual void device_reset() { shared_reset(); m_mode = MODE_16M_8k; }; - virtual void set_additional_wirings(UINT8 mask, int shift) { m_mask = mask; m_shift = shift; } // these get set at cart loading + virtual void set_additional_wirings(UINT8 mask, int shift) { m_mask = mask; m_shift = shift; } // these get set at cart loading virtual DECLARE_READ8_MEMBER(read_rom); virtual DECLARE_WRITE8_MEMBER(write_bank); @@ -156,19 +156,19 @@ public: class gb_rom_m161_device : public gb_rom_mbc_device { public: - + // construction/destruction gb_rom_m161_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); - + // device-level overrides virtual void device_start(); virtual void device_reset(); - + virtual DECLARE_READ8_MEMBER(read_rom); virtual DECLARE_WRITE8_MEMBER(write_bank); virtual DECLARE_READ8_MEMBER(read_ram) { return 0xff; } virtual DECLARE_WRITE8_MEMBER(write_ram) { } - + UINT8 m_base_bank; }; @@ -194,19 +194,19 @@ public: class gb_rom_sachen1_device : public gb_rom_mbc1_device { public: - + // construction/destruction gb_rom_sachen1_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); - + // device-level overrides virtual void device_start(); virtual void device_reset(); - + virtual DECLARE_READ8_MEMBER(read_rom); virtual DECLARE_WRITE8_MEMBER(write_bank); virtual DECLARE_READ8_MEMBER(read_ram) { return 0xff; } virtual DECLARE_WRITE8_MEMBER(write_ram) { } - + UINT8 m_base_bank, m_mask; }; diff --git a/src/emu/bus/ieee488/c2040.c b/src/emu/bus/ieee488/c2040.c index 4eb7c265660..273756742a5 100644 --- a/src/emu/bus/ieee488/c2040.c +++ b/src/emu/bus/ieee488/c2040.c @@ -11,29 +11,29 @@ /* - 2040/3040 disk initialization - ----------------------------- - You need to initialize each diskette before trying to access it - or you will get a DISK ID MISMATCH error upon disk commands. - On the 4040 this is done automatically by the DOS. + 2040/3040 disk initialization + ----------------------------- + You need to initialize each diskette before trying to access it + or you will get a DISK ID MISMATCH error upon disk commands. + On the 4040 this is done automatically by the DOS. - open 15,8,15:print 15,"i":close 15 + open 15,8,15:print 15,"i":close 15 - List directory - -------------- - directory / diR + List directory + -------------- + directory / diR - Format disk - ----------- - header "label,id",d0,i01 + Format disk + ----------- + header "label,id",d0,i01 - Load file - --------- - dload "name" / dL"name + Load file + --------- + dload "name" / dL"name - Save file - --------- - dsave "name" / dS"name + Save file + --------- + dsave "name" / dS"name */ diff --git a/src/emu/bus/ieee488/c2040fdc.c b/src/emu/bus/ieee488/c2040fdc.c index 026d0a37757..3881ff643f6 100644 --- a/src/emu/bus/ieee488/c2040fdc.c +++ b/src/emu/bus/ieee488/c2040fdc.c @@ -11,7 +11,7 @@ /* - TODO: + TODO: - write protect - separate read/write methods diff --git a/src/emu/bus/ieee488/c8050.h b/src/emu/bus/ieee488/c8050.h index 7d2ffdf0275..db87bffeab3 100644 --- a/src/emu/bus/ieee488/c8050.h +++ b/src/emu/bus/ieee488/c8050.h @@ -32,7 +32,7 @@ // ======================> c8050_device class c8050_device : public device_t, - public device_ieee488_interface + public device_ieee488_interface { public: // construction/destruction @@ -53,7 +53,7 @@ public: DECLARE_WRITE8_MEMBER( via_pb_w ); DECLARE_READ8_MEMBER( pi_r ); DECLARE_WRITE8_MEMBER( pi_w ); - + DECLARE_FLOPPY_FORMATS( floppy_formats ); protected: diff --git a/src/emu/bus/ieee488/c8050fdc.c b/src/emu/bus/ieee488/c8050fdc.c index b45a1c5810f..86aea2522fc 100644 --- a/src/emu/bus/ieee488/c8050fdc.c +++ b/src/emu/bus/ieee488/c8050fdc.c @@ -11,7 +11,7 @@ /* - TODO: + TODO: - write protect - 75,format speed error,01,00,0 @@ -221,7 +221,7 @@ void c8050_fdc_t::ds_w(int ds) void c8050_fdc_t::set_floppy(floppy_connector *floppy0, floppy_connector *floppy1) { m_floppy0 = floppy0->get_device(); - + if (floppy1) { m_floppy1 = floppy1->get_device(); } diff --git a/src/emu/bus/ieee488/c8280.c b/src/emu/bus/ieee488/c8280.c index 8787fb99487..0265f0983d1 100644 --- a/src/emu/bus/ieee488/c8280.c +++ b/src/emu/bus/ieee488/c8280.c @@ -477,12 +477,12 @@ READ8_MEMBER( c8280_device::fk5_r ) bit description - 0 - 1 - 2 + 0 + 1 + 2 3 DCHG 4 TSID - 5 + 5 6 0 7 0 diff --git a/src/emu/bus/ieee488/c8280.h b/src/emu/bus/ieee488/c8280.h index 917d6bbf1e2..ecb519ace7d 100644 --- a/src/emu/bus/ieee488/c8280.h +++ b/src/emu/bus/ieee488/c8280.h @@ -30,7 +30,7 @@ // ======================> c8280_device class c8280_device : public device_t, - public device_ieee488_interface + public device_ieee488_interface { public: // construction/destruction diff --git a/src/emu/bus/isa/svga_cirrus.c b/src/emu/bus/isa/svga_cirrus.c index 888b56bdb5c..03e2413e984 100644 --- a/src/emu/bus/isa/svga_cirrus.c +++ b/src/emu/bus/isa/svga_cirrus.c @@ -93,7 +93,7 @@ void isa16_svga_cirrus_device::device_reset() /* - Generic CL-GD542x video card + Generic CL-GD542x video card */ ROM_START( clgd542x ) diff --git a/src/emu/bus/nes/nes_pcb.inc b/src/emu/bus/nes/nes_pcb.inc index 8674f6a1b6c..d96420d5cbd 100644 --- a/src/emu/bus/nes/nes_pcb.inc +++ b/src/emu/bus/nes/nes_pcb.inc @@ -313,7 +313,7 @@ static const nes_pcb pcb_list[] = { "bmc_hik_kof", UNSUPPORTED_BOARD }, { "onebus", UNSUPPORTED_BOARD }, { "coolboy", UNSUPPORTED_BOARD }, - { "btl_900218", UNSUPPORTED_BOARD }, // pirate The Lord of King, to be emulated soon + { "btl_900218", UNSUPPORTED_BOARD }, // pirate The Lord of King, to be emulated soon { "a9746", UNSUPPORTED_BOARD }, { "dance2k", UNSUPPORTED_BOARD }, { "pec586", UNSUPPORTED_BOARD }, diff --git a/src/emu/bus/nubus/nubus_specpdq.c b/src/emu/bus/nubus/nubus_specpdq.c index f7c3abc2998..8a928177706 100644 --- a/src/emu/bus/nubus/nubus_specpdq.c +++ b/src/emu/bus/nubus/nubus_specpdq.c @@ -83,7 +83,7 @@ const rom_entry *nubus_specpdq_device::device_rom_region() const nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : device_t(mconfig, NUBUS_SPECPDQ, "SuperMac Spectrum PDQ video card", tag, owner, clock, "nb_spdq", __FILE__), device_video_interface(mconfig, *this), - device_nubus_card_interface(mconfig, *this), + device_nubus_card_interface(mconfig, *this), m_palette(*this, "palette") { m_assembled_tag = std::string(tag).append(":").append(SPECPDQ_SCREEN_NAME); diff --git a/src/emu/bus/nubus/pds30_mc30.c b/src/emu/bus/nubus/pds30_mc30.c index 87067bf4602..43b078ed588 100644 --- a/src/emu/bus/nubus/pds30_mc30.c +++ b/src/emu/bus/nubus/pds30_mc30.c @@ -65,7 +65,7 @@ const rom_entry *nubus_xceedmc30_device::device_rom_region() const nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : device_t(mconfig, PDS030_XCEEDMC30, "Micron/XCEED Technology MacroColor 30", tag, owner, clock, "pd3_mclr", __FILE__), device_video_interface(mconfig, *this), - device_nubus_card_interface(mconfig, *this) + device_nubus_card_interface(mconfig, *this) { m_assembled_tag = std::string(tag).append(":").append(XCEEDMC30_SCREEN_NAME); m_screen_tag = m_assembled_tag.c_str(); diff --git a/src/emu/bus/nubus/pds30_procolor816.c b/src/emu/bus/nubus/pds30_procolor816.c index f615ae2e988..7fca7b81bfa 100644 --- a/src/emu/bus/nubus/pds30_procolor816.c +++ b/src/emu/bus/nubus/pds30_procolor816.c @@ -68,7 +68,7 @@ const rom_entry *nubus_procolor816_device::device_rom_region() const nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : device_t(mconfig, PDS030_PROCOLOR816, "Lapis ProColor Server 8*16", tag, owner, clock, "pd3_pc16", __FILE__), device_video_interface(mconfig, *this), - device_nubus_card_interface(mconfig, *this) + device_nubus_card_interface(mconfig, *this) { m_assembled_tag = std::string(tag).append(":").append(PROCOLOR816_SCREEN_NAME); m_screen_tag = m_assembled_tag.c_str(); diff --git a/src/emu/bus/ti99_peb/hfdc.c b/src/emu/bus/ti99_peb/hfdc.c index 42bec79a255..b4ca2c415b7 100644 --- a/src/emu/bus/ti99_peb/hfdc.c +++ b/src/emu/bus/ti99_peb/hfdc.c @@ -74,7 +74,7 @@ #define CLK_ADDR 0x0fe0 #define RAM_ADDR 0x1000 -#define TRACE_EMU 1 +#define TRACE_EMU 1 #define TRACE_CRU 0 #define TRACE_COMP 0 #define TRACE_RAM 0 @@ -574,15 +574,15 @@ void myarc_hfdc_device::signal_drive_status() if ((m_current_floppy != NULL) && (!m_current_floppy->trk00_r())) reply |= HDC_DS_TRK00; } - else + else { if ((m_output1_latch & 0xe0)!=0) { if (m_current_harddisk != NULL) { - if (m_current_harddisk->ready_r()==ASSERT_LINE) + if (m_current_harddisk->ready_r()==ASSERT_LINE) { - m_status_latch |= HDC_DS_READY; + m_status_latch |= HDC_DS_READY; set_bits(m_status_latch, HDC_DS_SKCOM, m_current_harddisk->seek_complete_r()==ASSERT_LINE); set_bits(m_status_latch, HDC_DS_TRK00, m_current_harddisk->trk00_r()==ASSERT_LINE); } @@ -632,13 +632,13 @@ WRITE8_MEMBER( myarc_hfdc_device::auxbus_out ) m_output1_latch = data; - if ((data & 0x10) != 0) connect_floppy_unit(bit_to_index(data & 0x0f)); // Floppy selected + if ((data & 0x10) != 0) connect_floppy_unit(bit_to_index(data & 0x0f)); // Floppy selected else { index = bit_to_index((data>>4) & 0x0f); - if (index > 0) connect_harddisk_unit(index-1); // HD selected; index >= 1 - else + if (index > 0) connect_harddisk_unit(index-1); // HD selected; index >= 1 + else { disconnect_floppy_drives(); disconnect_hard_drives(); @@ -668,7 +668,7 @@ WRITE8_MEMBER( myarc_hfdc_device::auxbus_out ) m_current_floppy->dir_w((data & 0x20)==0); m_current_floppy->stp_w((data & 0x10)==0); } - + if (m_current_harddisk != NULL) { // Dir = 0 -> outward @@ -695,10 +695,10 @@ void myarc_hfdc_device::connect_floppy_unit(int index) { disconnect_floppy_drives(); if (TRACE_LINES) logerror("%s: Select floppy drive DSK%d\n", tag(), index+1); - + // Connect new drive m_current_floppy = m_floppy_unit[index]; - + // We don't use the READY line of floppy drives. // READY is asserted when DSKx = 1 // The controller fetches the state with the auxbus access @@ -709,8 +709,8 @@ void myarc_hfdc_device::connect_floppy_unit(int index) logerror("%s: Connection to DSK%d failed because no drive is connected\n", tag(), index+1); m_hdc9234->connect_floppy_drive(m_floppy_unit[index]); } - - // We can only run a floppy or a harddisk at a time, not both + + // We can only run a floppy or a harddisk at a time, not both disconnect_hard_drives(); } @@ -720,10 +720,10 @@ void myarc_hfdc_device::connect_harddisk_unit(int index) { disconnect_hard_drives(); if (TRACE_LINES) logerror("%s: Select hard disk WDS%d\n", tag(), index+1); - + // Connect new drive m_current_harddisk = m_harddisk_unit[index]; - + if (TRACE_LINES) logerror("%s: Connect index callback WDS%d\n", tag(), index+1); if (m_current_harddisk != NULL) { @@ -735,7 +735,7 @@ void myarc_hfdc_device::connect_harddisk_unit(int index) m_hdc9234->connect_hard_drive(m_current_harddisk); } - // We can only run a floppy or a harddisk at a time, not both + // We can only run a floppy or a harddisk at a time, not both disconnect_floppy_drives(); } @@ -756,7 +756,7 @@ void myarc_hfdc_device::disconnect_hard_drives() if (m_current_harddisk != NULL) { m_current_harddisk->setup_index_pulse_cb(mfm_harddisk_device::index_pulse_cb()); - m_current_harddisk->setup_seek_complete_cb(mfm_harddisk_device::seek_complete_cb()); + m_current_harddisk->setup_seek_complete_cb(mfm_harddisk_device::seek_complete_cb()); m_current_harddisk = NULL; } } @@ -917,15 +917,15 @@ void myarc_hfdc_device::device_config_complete() m_harddisk_unit[i] = NULL; } m_floppy_unit[3] = NULL; - + // Seems to be null when doing a "-listslots" - if (subdevice("f1")!=NULL) + if (subdevice("f1")!=NULL) { m_floppy_unit[0] = static_cast<floppy_connector*>(subdevice("f1"))->get_device(); m_floppy_unit[1] = static_cast<floppy_connector*>(subdevice("f2"))->get_device(); m_floppy_unit[2] = static_cast<floppy_connector*>(subdevice("f3"))->get_device(); m_floppy_unit[3] = static_cast<floppy_connector*>(subdevice("f4"))->get_device(); - + m_harddisk_unit[0] = static_cast<mfm_harddisk_connector*>(subdevice("h1"))->get_device(); m_harddisk_unit[1] = static_cast<mfm_harddisk_connector*>(subdevice("h2"))->get_device(); m_harddisk_unit[2] = static_cast<mfm_harddisk_connector*>(subdevice("h3"))->get_device(); @@ -993,8 +993,8 @@ static SLOT_INTERFACE_START( hfdc_floppies ) SLOT_INTERFACE_END static SLOT_INTERFACE_START( hfdc_harddisks ) - SLOT_INTERFACE( "generic", MFM_HD_GENERIC ) // Generic high-level emulation -// SLOT_INTERFACE( "seagatemfm", MFM_HD_SEAGATE ) // Seagate ST-225 and others + SLOT_INTERFACE( "generic", MFM_HD_GENERIC ) // Generic high-level emulation +// SLOT_INTERFACE( "seagatemfm", MFM_HD_SEAGATE ) // Seagate ST-225 and others SLOT_INTERFACE_END MACHINE_CONFIG_FRAGMENT( ti99_hfdc ) @@ -1015,7 +1015,7 @@ MACHINE_CONFIG_FRAGMENT( ti99_hfdc ) MCFG_MFM_HARDDISK_ADD("h1", hfdc_harddisks, NULL) MCFG_MFM_HARDDISK_ADD("h2", hfdc_harddisks, NULL) MCFG_MFM_HARDDISK_ADD("h3", hfdc_harddisks, NULL) - + MCFG_DEVICE_ADD(CLOCK_TAG, MM58274C, 0) MCFG_MM58274C_MODE24(1) // 24 hour MCFG_MM58274C_DAY1(0) // sunday @@ -1478,8 +1478,8 @@ MACHINE_CONFIG_FRAGMENT( ti99_hfdc_legacy ) MCFG_DEVICE_ADD(CLOCK_TAG, MM58274C, 0) MCFG_MM58274C_MODE24(1) // 24 hour MCFG_MM58274C_DAY1(0) // sunday - - MCFG_MFMHD_3_DRIVES_ADD() // add hard disks + + MCFG_MFMHD_3_DRIVES_ADD() // add hard disks MACHINE_CONFIG_END ROM_START( ti99_hfdc_legacy ) diff --git a/src/emu/bus/ti99_peb/hfdc.h b/src/emu/bus/ti99_peb/hfdc.h index 5ba2d816be1..a22ede259d9 100644 --- a/src/emu/bus/ti99_peb/hfdc.h +++ b/src/emu/bus/ti99_peb/hfdc.h @@ -52,7 +52,7 @@ public: protected: void device_config_complete(); - + private: void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr); void device_start(); @@ -70,7 +70,7 @@ private: void floppy_index_callback(floppy_image_device *floppy, int state); void harddisk_index_callback(mfm_harddisk_device *harddisk, int state); void harddisk_skcom_callback(mfm_harddisk_device *harddisk, int state); - + // Operate the floppy motors void set_floppy_motors_running(bool run); @@ -184,7 +184,7 @@ private: /* Connector for a MFM hard disk. See also floppy.c */ class mfm_harddisk_connector : public device_t, - public device_slot_interface + public device_slot_interface { public: mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); diff --git a/src/emu/cpu/dsp16/dsp16dis.c b/src/emu/cpu/dsp16/dsp16dis.c index 2aed7e0f0b8..09d6e2d149a 100644 --- a/src/emu/cpu/dsp16/dsp16dis.c +++ b/src/emu/cpu/dsp16/dsp16dis.c @@ -101,7 +101,7 @@ std::string disasmF2Field(const UINT8& F2, const UINT8& D, const UINT8& S) case 0x05: strprintf(ret, "a%d = a%d << 8", D, S); break; case 0x06: strprintf(ret, "a%d = a%d >> 16", D, S); break; case 0x07: strprintf(ret, "a%d = a%d << 16", D, S); break; - + case 0x08: strprintf(ret, "a%d = p", D); break; case 0x09: strprintf(ret, "a%dh = a%dh + 1", D, S); break; case 0x0a: strprintf(ret, "RESERVED"); break; diff --git a/src/emu/cpu/m68000/m68kops.c b/src/emu/cpu/m68000/m68kops.c index cbb37a99d28..436df1df763 100644 --- a/src/emu/cpu/m68000/m68kops.c +++ b/src/emu/cpu/m68000/m68kops.c @@ -34882,5 +34882,3 @@ void m68ki_build_opcode_table(void) /* ======================================================================== */ /* ============================== END OF FILE ============================= */ /* ======================================================================== */ - - diff --git a/src/emu/cpu/mcs51/mcs51.h b/src/emu/cpu/mcs51/mcs51.h index efca4c8de16..d02bb02797d 100644 --- a/src/emu/cpu/mcs51/mcs51.h +++ b/src/emu/cpu/mcs51/mcs51.h @@ -150,7 +150,7 @@ protected: UINT8 m_irq_active; /* mask which irq levels are serviced */ UINT8 m_irq_prio[8]; /* interrupt priority */ - UINT8 m_forced_inputs[4]; /* allow read even if configured as output */ + UINT8 m_forced_inputs[4]; /* allow read even if configured as output */ int m_icount; diff --git a/src/emu/cpu/mips/mips3.h b/src/emu/cpu/mips/mips3.h index 5d5d61354d7..e527b4715b4 100644 --- a/src/emu/cpu/mips/mips3.h +++ b/src/emu/cpu/mips/mips3.h @@ -396,8 +396,8 @@ private: /* memory accesses */ bool m_bigendian; - UINT32 m_byte_xor; - UINT32 m_word_xor; + UINT32 m_byte_xor; + UINT32 m_word_xor; data_accessors m_memory; /* cache memory */ diff --git a/src/emu/cpu/nec/v53.c b/src/emu/cpu/nec/v53.c index 36e8d9da5a4..bbec2d042e3 100644 --- a/src/emu/cpu/nec/v53.c +++ b/src/emu/cpu/nec/v53.c @@ -477,8 +477,8 @@ static MACHINE_CONFIG_FRAGMENT( v53 ) MCFG_DEVICE_ADD("pit", PIT8254, 0) // functionality identical to uPD71054 MCFG_PIT8253_CLK0(16000000) // manual implicitly claims that these runs at same speed as the CPU - MCFG_PIT8253_CLK1(16000000) - MCFG_PIT8253_CLK2(16000000) + MCFG_PIT8253_CLK1(16000000) + MCFG_PIT8253_CLK2(16000000) MCFG_PIT8253_OUT0_HANDLER(WRITELINE( v53_base_device, tcu_out0_trampoline_cb )) MCFG_PIT8253_OUT1_HANDLER(WRITELINE( v53_base_device, tcu_out1_trampoline_cb )) MCFG_PIT8253_OUT2_HANDLER(WRITELINE( v53_base_device, tcu_out2_trampoline_cb )) diff --git a/src/emu/cpu/sh4/sh4.c b/src/emu/cpu/sh4/sh4.c index eed99ceca33..3b294fcf503 100644 --- a/src/emu/cpu/sh4/sh4.c +++ b/src/emu/cpu/sh4/sh4.c @@ -100,8 +100,8 @@ sh34_base_device::sh34_base_device(const machine_config &mconfig, device_type ty #if SH4_USE_FASTRAM_OPTIMIZATION , m_bigendian(endianness == ENDIANNESS_BIG) , m_byte_xor(m_bigendian ? BYTE8_XOR_BE(0) : BYTE8_XOR_LE(0)) - , m_word_xor(m_bigendian ? WORD2_XOR_BE(0) : WORD2_XOR_LE(0)) - , m_dword_xor(m_bigendian ? DWORD_XOR_BE(0) : DWORD_XOR_LE(0)) + , m_word_xor(m_bigendian ? WORD2_XOR_BE(0) : WORD2_XOR_LE(0)) + , m_dword_xor(m_bigendian ? DWORD_XOR_BE(0) : DWORD_XOR_LE(0)) , m_fastram_select(0) #endif { diff --git a/src/emu/cpu/sh4/sh4.h b/src/emu/cpu/sh4/sh4.h index e7ad4fd9cb0..5a621b8cfc7 100644 --- a/src/emu/cpu/sh4/sh4.h +++ b/src/emu/cpu/sh4/sh4.h @@ -693,9 +693,9 @@ protected: #if SH4_USE_FASTRAM_OPTIMIZATION /* fast RAM */ bool m_bigendian; - UINT32 m_byte_xor; - UINT32 m_word_xor; - UINT32 m_dword_xor; + UINT32 m_byte_xor; + UINT32 m_word_xor; + UINT32 m_dword_xor; UINT32 m_fastram_select; struct { diff --git a/src/emu/cpu/tms0980/tms0980.c b/src/emu/cpu/tms0980/tms0980.c index 142f894cdf4..3c1db6c8a3d 100644 --- a/src/emu/cpu/tms0980/tms0980.c +++ b/src/emu/cpu/tms0980/tms0980.c @@ -3,7 +3,7 @@ /* TMS0980/TMS1000-family MCU cores - + TODO: - emulate TMS1600 L-pins - fix debugger disasm view diff --git a/src/emu/debug/debugcpu.h b/src/emu/debug/debugcpu.h index 1cfacc267b0..2f1f90c4ef7 100644 --- a/src/emu/debug/debugcpu.h +++ b/src/emu/debug/debugcpu.h @@ -236,7 +236,7 @@ public: void registerpoint_enable_all(bool enable = true ); // hotspots - bool hotspot_tracking_enabled() const { return !m_hotspots.empty(); } + bool hotspot_tracking_enabled() const { return !m_hotspots.empty(); } void hotspot_track(int numspots, int threshhold); // comments diff --git a/src/emu/diimage.c b/src/emu/diimage.c index 060e2a1b040..e4c40167114 100644 --- a/src/emu/diimage.c +++ b/src/emu/diimage.c @@ -805,7 +805,7 @@ bool device_image_interface::load_software(software_list_device &swlist, const c int separator = tag4.find_first_of('%'); if (separator != -1) { - // we are loading a clone through softlists, split the setname from the parentname + // we are loading a clone through softlists, split the setname from the parentname tag5.assign(tag4.substr(separator + 1, tag4.length() - separator + 1)); tag4.erase(separator, tag4.length() - separator); } diff --git a/src/emu/drivenum.c b/src/emu/drivenum.c index 9491f223a2e..6d1590c030b 100644 --- a/src/emu/drivenum.c +++ b/src/emu/drivenum.c @@ -134,7 +134,7 @@ driver_enumerator::driver_enumerator(emu_options &options) m_included(s_driver_count), m_config(s_driver_count) { - memset(&m_included[0], 0, s_driver_count); + memset(&m_included[0], 0, s_driver_count); memset(&m_config[0], 0, s_driver_count*sizeof(m_config[0])); include_all(); } @@ -147,7 +147,7 @@ driver_enumerator::driver_enumerator(emu_options &options, const char *string) m_included(s_driver_count), m_config(s_driver_count) { - memset(&m_included[0], 0, s_driver_count); + memset(&m_included[0], 0, s_driver_count); memset(&m_config[0], 0, s_driver_count*sizeof(m_config[0])); filter(string); } @@ -160,7 +160,7 @@ driver_enumerator::driver_enumerator(emu_options &options, const game_driver &dr m_included(s_driver_count), m_config(s_driver_count) { - memset(&m_included[0], 0, s_driver_count); + memset(&m_included[0], 0, s_driver_count); memset(&m_config[0], 0, s_driver_count*sizeof(m_config[0])); filter(driver); } diff --git a/src/emu/imagedev/harddriv.c b/src/emu/imagedev/harddriv.c index 73baeb54e14..9f88760f1d7 100644 --- a/src/emu/imagedev/harddriv.c +++ b/src/emu/imagedev/harddriv.c @@ -49,7 +49,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 *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source) : device_t(mconfig, type, name, tag, owner, clock, shortname, source), device_image_interface(mconfig, *this), diff --git a/src/emu/info.c b/src/emu/info.c index 9cb59d5c0cc..462b94ab652 100644 --- a/src/emu/info.c +++ b/src/emu/info.c @@ -1080,7 +1080,7 @@ void info_xml_creator::output_switches(const ioport_list &portlist, const char * std::string output; std::string newtag(port->tag()), oldtag(":"); - newtag = newtag.substr(newtag.find(oldtag.append(root_tag).c_str()) + oldtag.length()); + newtag = newtag.substr(newtag.find(oldtag.append(root_tag).c_str()) + oldtag.length()); // output the switch name information std::string normalized_field_name(xml_normalize_string(field->name())); diff --git a/src/emu/machine/hdc9234.c b/src/emu/machine/hdc9234.c index f3b6077db3f..c77783e463c 100644 --- a/src/emu/machine/hdc9234.c +++ b/src/emu/machine/hdc9234.c @@ -240,7 +240,7 @@ enum { GEN_TIMER = 1, COM_TIMER /*, - LIVE_TIMER */ + LIVE_TIMER */ }; /* @@ -1820,7 +1820,7 @@ void hdc9234_device::live_run() the requested data are read. limit: if unlimited (attotime::never), run up to the end of the track and wait there otherwise, used to replay the read/write operation up to the point where the event happened - + THIS IS THE FLOPPY-ONLY LIVE_RUN */ void hdc9234_device::live_run_until(attotime limit) @@ -2632,12 +2632,12 @@ void hdc9234_device::live_run_until(attotime limit) the requested data are read. limit: if unlimited (attotime::never), run up to the end of the track and wait there otherwise, used to replay the read/write operation up to the point where the event happened - + THIS IS THE HARDDISK-ONLY LIVE_RUN */ void hdc9234_device::live_run_hd_until(attotime limit) { -// int slot = 0; +// int slot = 0; logerror("%s: live_run_hd\n", tag()); if (m_live_state.state == IDLE || m_live_state.next_state != -1) @@ -2656,7 +2656,7 @@ void hdc9234_device::live_run_hd_until(attotime limit) { case SEARCH_IDAM: break; - } + } return; } } @@ -3411,8 +3411,8 @@ void hdc9234_device::device_timer(emu_timer &timer, device_timer_id id, int para process_command(); break; /* case LIVE_TIMER: - live_run(); - break; */ + live_run(); + break; */ } } diff --git a/src/emu/machine/hdc9234.h b/src/emu/machine/hdc9234.h index a933f6b1959..8317545c552 100644 --- a/src/emu/machine/hdc9234.h +++ b/src/emu/machine/hdc9234.h @@ -227,7 +227,7 @@ private: // Analyses the track until the given time void live_run_until(attotime limit); - + // Same for hard disks void live_run_hd_until(attotime limit); diff --git a/src/emu/machine/mos6530n.c b/src/emu/machine/mos6530n.c index 70af89279bd..64e13126a1c 100644 --- a/src/emu/machine/mos6530n.c +++ b/src/emu/machine/mos6530n.c @@ -247,7 +247,7 @@ void mos6530_t::update_pb() } else { - m_out_pb_cb(data); + m_out_pb_cb(data); } } diff --git a/src/emu/machine/mos6530n.h b/src/emu/machine/mos6530n.h index 88cd4a56558..22be75989b4 100644 --- a/src/emu/machine/mos6530n.h +++ b/src/emu/machine/mos6530n.h @@ -46,7 +46,7 @@ //************************************************************************** #define MCFG_MOS6530n_IRQ_CB(_write) \ - devcb = &mos6530_t::set_irq_wr_callback(*device, DEVCB_##_write); + devcb = &mos6530_t::set_irq_wr_callback(*device, DEVCB_##_write); #define MCFG_MOS6530n_IN_PA_CB(_read) \ devcb = &mos6530_t::set_pa_rd_callback(*device, DEVCB_##_read); diff --git a/src/emu/machine/pci9050.c b/src/emu/machine/pci9050.c index 258118df1fd..ed8e58e2497 100644 --- a/src/emu/machine/pci9050.c +++ b/src/emu/machine/pci9050.c @@ -1,9 +1,9 @@ /********************************************************************* pci9050.c - PLX PCI9050 PCI to 4x Local Bus Bridge - - by R. Belmont - + + by R. Belmont + PCI spaces: 0 - (config memory) not used 1 - (config I/O) config regs @@ -11,12 +11,12 @@ 3 - local bus 2 window 4 - local bus 3 window 5 - local bus 4 window - + PCI9050 is located, mapped, and initialized at BFC00700. - - The boot ROM then copies ROM to RAM, jumps to RAM, and starts trying to + + The boot ROM then copies ROM to RAM, jumps to RAM, and starts trying to access Zeus 2 video through the mapped windows. - + *********************************************************************/ #include "pci9050.h" @@ -66,12 +66,12 @@ void pci9050_device::device_start() pci_device::device_start(); - add_map(0x100, M_MEM, FUNC(pci9050_device::map)); // map 0 is our config registers, mem space - add_map(0x100, M_IO, FUNC(pci9050_device::map)); // map 1 is our config registers, i/o space + add_map(0x100, M_MEM, FUNC(pci9050_device::map)); // map 0 is our config registers, mem space + add_map(0x100, M_IO, FUNC(pci9050_device::map)); // map 1 is our config registers, i/o space for(int i=0; i<4; i++) if(m_names[i]) - // add_map(0, M_MEM | M_DISABLED, m_maps[i], m_names[i], m_devices[i]); + // add_map(0, M_MEM | M_DISABLED, m_maps[i], m_names[i], m_devices[i]); add_map(0, M_MEM | M_DISABLED, trampolines[i], m_names[i]); else add_map(0, M_MEM | M_DISABLED, FUNC(pci9050_device::empty)); @@ -119,8 +119,8 @@ void pci9050_device::remap_local(int id) int size = 2 << lsize; if(csbase & 0x0fffffff & ~(size-1)) { logerror("PCI9050 local bus %d disabled due to unimplemented post-decode remapping\n", id); - // set_map_flags(id+2, M_MEM | M_DISABLED); - // return; + // set_map_flags(id+2, M_MEM | M_DISABLED); + // return; } UINT32 mask = ~(size - 1); @@ -131,8 +131,8 @@ void pci9050_device::remap_local(int id) if((lasrr & mask) != mask) { logerror("PCI9050 local bus %d disabled due to unimplemented pci mirroring\n", id); - // set_map_flags(id+2, M_MEM | M_DISABLED); - // return; + // set_map_flags(id+2, M_MEM | M_DISABLED); + // return; } set_map_size(id+2, size); diff --git a/src/emu/machine/pci9050.h b/src/emu/machine/pci9050.h index 88167adbb03..556290ad81c 100644 --- a/src/emu/machine/pci9050.h +++ b/src/emu/machine/pci9050.h @@ -1,9 +1,9 @@ /********************************************************************* pci9050.h - PLX PCI9050 PCI to 4x Local Bus Bridge - - by R. Belmont - + + by R. Belmont + *********************************************************************/ #ifndef _PCI9050_H @@ -17,7 +17,7 @@ #define MCFG_PCI9050_SET_MAP(id, map) \ downcast<pci9050_device *>(device)->set_map(id, ADDRESS_MAP_NAME(map), #map, owner); -class pci9050_device : +class pci9050_device : public pci_device { public: diff --git a/src/emu/machine/ti99_hd.c b/src/emu/machine/ti99_hd.c index 87946c42990..96627f0978d 100644 --- a/src/emu/machine/ti99_hd.c +++ b/src/emu/machine/ti99_hd.c @@ -11,7 +11,7 @@ References: [1] ST225 OEM Manual, Seagate - + **************************************************************************/ #include "emu.h" @@ -31,7 +31,7 @@ #define GAP4 340 #define SYNC 13 -enum +enum { INDEX_TM = 0, SPINUP_TM, @@ -47,7 +47,7 @@ enum mfm_harddisk_device::mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source) : harddisk_image_device(mconfig, type, name, tag, owner, clock, shortname, source), - device_slot_card_interface(mconfig, *this) + device_slot_card_interface(mconfig, *this) { } @@ -56,7 +56,7 @@ void mfm_harddisk_device::device_start() m_index_timer = timer_alloc(INDEX_TM); m_spinup_timer = timer_alloc(SPINUP_TM); m_seek_timer = timer_alloc(SEEK_TM); - + // MFM drives have a revolution rate of 3600 rpm (i.e. 60/sec) m_index_timer->adjust(attotime::from_hz(60), 0, attotime::from_hz(60)); @@ -112,12 +112,12 @@ void mfm_harddisk_device::device_timer(emu_timer &timer, device_timer_id id, int case STEP_MOVING: // Head has reached final position // Check whether we have a new delta - if (m_track_delta == 0) + if (m_track_delta == 0) { // Start the settle timer m_step_phase = STEP_SETTLE; m_seek_timer->adjust(attotime::from_usec(16800)); - logerror("%s: Arrived at target track %d, settling ...\n", tag(), m_current_cylinder); + logerror("%s: Arrived at target track %d, settling ...\n", tag(), m_current_cylinder); } break; case STEP_SETTLE: @@ -126,7 +126,7 @@ void mfm_harddisk_device::device_timer(emu_timer &timer, device_timer_id id, int else { // Seek completed - logerror("%s: Settling done at cylinder %d, seek complete\n", tag(), m_current_cylinder); + logerror("%s: Settling done at cylinder %d, seek complete\n", tag(), m_current_cylinder); m_seek_complete = true; m_seek_complete_cb(this, ASSERT_LINE); m_step_phase = STEP_COLLECT; @@ -136,11 +136,11 @@ void mfm_harddisk_device::device_timer(emu_timer &timer, device_timer_id id, int } } -void mfm_harddisk_device::head_move() +void mfm_harddisk_device::head_move() { int steps = m_track_delta; - if (steps < 0) steps = -steps; - logerror("%s: Moving head by %d step(s) %s\n", tag(), steps, (m_track_delta<0)? "outward" : "inward"); + if (steps < 0) steps = -steps; + logerror("%s: Moving head by %d step(s) %s\n", tag(), steps, (m_track_delta<0)? "outward" : "inward"); int disttime = steps*200; m_step_phase = STEP_MOVING; @@ -153,72 +153,72 @@ void mfm_harddisk_device::head_move() m_track_delta = 0; } -void mfm_harddisk_device::direction_in_w(line_state line) +void mfm_harddisk_device::direction_in_w(line_state line) { m_seek_inward = (line == ASSERT_LINE); logerror("%s: Setting seek direction %s\n", tag(), m_seek_inward? "inward" : "outward"); } /* - According to the specs [1]: - - "4.3.1 BUFFERED SEEK: To minimize access time, pulses may be issued at an - accelerated rate and buffered in a counter. Initiation of a seek starts - immediately after the first pulse is received. Head motion occurs during - pulse accumulation, and the seek is completed following receipt of all pulses." - - "8.1.3 SEEKING: Upon receiving a Step pulse, the MPU (microprocessor unit) + According to the specs [1]: + + "4.3.1 BUFFERED SEEK: To minimize access time, pulses may be issued at an + accelerated rate and buffered in a counter. Initiation of a seek starts + immediately after the first pulse is received. Head motion occurs during + pulse accumulation, and the seek is completed following receipt of all pulses." + + "8.1.3 SEEKING: Upon receiving a Step pulse, the MPU (microprocessor unit) pauses for 250 usec to allow for additional pulses before executing the seek - operation. Every incoming pulse resets the 250 usec timer. The seek will - not begin until the last pulse is received." - - WTF? Oh come on, Seagate, be consistent at least in a single document. - - ================================ - - Step behaviour: - During all waiting times, further step_w invocations increase the counter - - - Leading edge increments the counter c and sets the timer to 250us (mode=collect) - - When the timer expires (mode=collect): + operation. Every incoming pulse resets the 250 usec timer. The seek will + not begin until the last pulse is received." + + WTF? Oh come on, Seagate, be consistent at least in a single document. + + ================================ + + Step behaviour: + During all waiting times, further step_w invocations increase the counter + + - Leading edge increments the counter c and sets the timer to 250us (mode=collect) + - When the timer expires (mode=collect): (1)- Calculate the stepping time: time = c*200us; save the counter - - Start the timer (mode=move) - - When the timer expires (mode=move) - - Add the track delta to the current track position - - Subtract the delta from the current counter - - When the counter is not zero (pulses arrived in the meantime), go to (1) - - When the counter is zero, set the timer to 16.8 ms (mode=settle) - - When the timer expires (mode=settle) - - When the counter is not zero, go to (1) - - When the counter is zero, signal seek_complete; done - + - Start the timer (mode=move) + - When the timer expires (mode=move) + - Add the track delta to the current track position + - Subtract the delta from the current counter + - When the counter is not zero (pulses arrived in the meantime), go to (1) + - When the counter is zero, set the timer to 16.8 ms (mode=settle) + - When the timer expires (mode=settle) + - When the counter is not zero, go to (1) + - When the counter is zero, signal seek_complete; done + Step timing: - per track = 20 ms max, full seek: 150 ms max (615 tracks); both including settling time - We assume t(1) = 17; t(615)=140 - t(i) = s+d*i - s=(615*t(1)-t(615))/614 - d=t(1)-s - s=16800 us, d=200 us -*/ - -void mfm_harddisk_device::step_w(line_state line) + per track = 20 ms max, full seek: 150 ms max (615 tracks); both including settling time + We assume t(1) = 17; t(615)=140 + t(i) = s+d*i + s=(615*t(1)-t(615))/614 + d=t(1)-s + s=16800 us, d=200 us +*/ + +void mfm_harddisk_device::step_w(line_state line) { // Leading edge if (line == ASSERT_LINE && m_step_line == CLEAR_LINE) { - if (m_seek_complete) + if (m_seek_complete) { - m_step_phase = STEP_COLLECT; + m_step_phase = STEP_COLLECT; m_seek_complete = false; m_seek_complete_cb(this, CLEAR_LINE); } // Counter will be adjusted according to the direction (+-1) - m_track_delta += (m_seek_inward)? +1 : -1; + m_track_delta += (m_seek_inward)? +1 : -1; logerror("%s: Got seek pulse; track delta %d\n", tag(), m_track_delta); - if (m_track_delta < -670 || m_track_delta > 670) + if (m_track_delta < -670 || m_track_delta > 670) { - logerror("%s: Excessive step pulses - doing auto-truncation\n", tag()); + logerror("%s: Excessive step pulses - doing auto-truncation\n", tag()); m_autotruncation = true; } m_seek_timer->adjust(attotime::from_usec(250)); diff --git a/src/emu/machine/ti99_hd.h b/src/emu/machine/ti99_hd.h index b31f5420fb3..bdeb80c8118 100644 --- a/src/emu/machine/ti99_hd.h +++ b/src/emu/machine/ti99_hd.h @@ -18,7 +18,7 @@ #include "imagedev/harddriv.h" class mfm_harddisk_device : public harddisk_image_device, - public device_slot_card_interface + public device_slot_card_interface { public: mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock, const char *shortname, const char *source); @@ -30,34 +30,34 @@ public: void setup_seek_complete_cb(seek_complete_cb cb); // Active low lines. We're using ASSERT=0 / CLEAR=1 - line_state ready_r() { return m_ready? ASSERT_LINE : CLEAR_LINE; } - line_state seek_complete_r() { return m_seek_complete? ASSERT_LINE : CLEAR_LINE; } ; - line_state trk00_r() { return m_current_cylinder==0? ASSERT_LINE : CLEAR_LINE; } + line_state ready_r() { return m_ready? ASSERT_LINE : CLEAR_LINE; } + line_state seek_complete_r() { return m_seek_complete? ASSERT_LINE : CLEAR_LINE; } ; + line_state trk00_r() { return m_current_cylinder==0? ASSERT_LINE : CLEAR_LINE; } // Step - void step_w(line_state line); - void direction_in_w(line_state line); - + void step_w(line_state line); + void direction_in_w(line_state line); + protected: - void device_start(); - void device_reset(); - emu_timer *m_index_timer, *m_spinup_timer, *m_seek_timer; - index_pulse_cb m_index_pulse_cb; - seek_complete_cb m_seek_complete_cb; - void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr); + void device_start(); + void device_reset(); + emu_timer *m_index_timer, *m_spinup_timer, *m_seek_timer; + index_pulse_cb m_index_pulse_cb; + seek_complete_cb m_seek_complete_cb; + void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr); private: - bool m_ready; - int m_current_cylinder; - int m_track_delta; - int m_step_phase; - bool m_seek_complete; - bool m_seek_inward; - //bool m_seeking; - bool m_autotruncation; - line_state m_step_line; // keep the last state - - void head_move(); + bool m_ready; + int m_current_cylinder; + int m_track_delta; + int m_step_phase; + bool m_seek_complete; + bool m_seek_inward; + //bool m_seeking; + bool m_autotruncation; + line_state m_step_line; // keep the last state + + void head_move(); }; class mfm_hd_generic_device : public mfm_harddisk_device diff --git a/src/emu/machine/vrc4373.h b/src/emu/machine/vrc4373.h index 51c774d4f9a..b620e9f6d20 100644 --- a/src/emu/machine/vrc4373.h +++ b/src/emu/machine/vrc4373.h @@ -45,15 +45,15 @@ #define NREG_PCIEN (0x074/4) #define NREG_PMIR (0x078/4) -#define DMA_BUSY 0x80000000 -#define DMA_INT_EN 0x40000000 -#define DMA_RW 0x20000000 -#define DMA_GO 0x10000000 -#define DMA_SUS 0x08000000 -#define DMA_INC 0x04000000 -#define DMA_MIO 0x02000000 -#define DMA_RST 0x01000000 -#define DMA_BLK_SIZE 0x000fffff +#define DMA_BUSY 0x80000000 +#define DMA_INT_EN 0x40000000 +#define DMA_RW 0x20000000 +#define DMA_GO 0x10000000 +#define DMA_SUS 0x08000000 +#define DMA_INC 0x04000000 +#define DMA_MIO 0x02000000 +#define DMA_RST 0x01000000 +#define DMA_BLK_SIZE 0x000fffff class vrc4373_device : public pci_host_device { diff --git a/src/emu/machine/z80pio.c b/src/emu/machine/z80pio.c index b53b3fe6158..ea5da25e221 100644 --- a/src/emu/machine/z80pio.c +++ b/src/emu/machine/z80pio.c @@ -11,9 +11,9 @@ /* - TODO: + TODO: - - if port A is bidirectional, port B does not issue interrupts in bit mode + - if port A is bidirectional, port B does not issue interrupts in bit mode */ @@ -255,7 +255,7 @@ void z80pio_device::check_interrupts() for (int index = PORT_A; index < PORT_COUNT; index++) { if (LOG) logerror("Z80PIO '%s' Port %c IE %s IP %s IUS %s\n", tag(), 'A' + index, m_port[index].m_ie ? "1":"0", m_port[index].m_ip ? "1":"0", m_port[index].m_ius ? "1":"0"); - + if (!ius && m_port[index].m_ie && m_port[index].m_ip) { state = ASSERT_LINE; diff --git a/src/emu/netlist/devices/net_lib.c b/src/emu/netlist/devices/net_lib.c index ef0873d376a..93efac4c1a7 100644 --- a/src/emu/netlist/devices/net_lib.c +++ b/src/emu/netlist/devices/net_lib.c @@ -122,7 +122,7 @@ void nl_initialize_factory(netlist_factory_t &factory) ENTRY(74175, TTL_74175, "-") ENTRY(74192, TTL_74192, "-") ENTRY(74193, TTL_74193, "-") - //ENTRY(74279, TTL_74279, "-") // only dip available + //ENTRY(74279, TTL_74279, "-") // only dip available ENTRY(SN74LS629, SN74LS629, "CAP") ENTRY(82S16, TTL_82S16, "-") ENTRY(9310, TTL_9310, "-") diff --git a/src/emu/netlist/devices/nld_74175.c b/src/emu/netlist/devices/nld_74175.c index b84f4d458ee..6d4db58703d 100644 --- a/src/emu/netlist/devices/nld_74175.c +++ b/src/emu/netlist/devices/nld_74175.c @@ -32,7 +32,7 @@ NETLIB_UPDATE(74175) NETLIB_START(74175) { - register_input("CLK", m_CLK); + register_input("CLK", m_CLK); register_input("CLRQ", m_CLRQ); register_input("D1", m_D[0]); @@ -60,7 +60,7 @@ NETLIB_RESET(74175) NETLIB_START(74175_dip) { - register_input("9", m_CLK); + register_input("9", m_CLK); register_input("1", m_CLRQ); register_input("4", m_D[0]); diff --git a/src/emu/netlist/devices/nld_74175.h b/src/emu/netlist/devices/nld_74175.h index 9c138755a50..28e7bc96d4e 100644 --- a/src/emu/netlist/devices/nld_74175.h +++ b/src/emu/netlist/devices/nld_74175.h @@ -39,8 +39,7 @@ #include "nld_signal.h" #define TTL_74175(_name) \ - NET_REGISTER_DEV(74175, _name) \ - + NET_REGISTER_DEV(74175, _name) #define TTL_74175_DIP(_name) \ NET_REGISTER_DEV(74175_dip, _name) diff --git a/src/emu/netlist/devices/nld_74192.h b/src/emu/netlist/devices/nld_74192.h index 017d51f558b..bc4a11a5360 100644 --- a/src/emu/netlist/devices/nld_74192.h +++ b/src/emu/netlist/devices/nld_74192.h @@ -4,7 +4,7 @@ * nld_74192.h * * DM74192: Synchronous 4-Bit Binary Counter with Dual Clock - * Decade counter + * Decade counter * * FIXME: This should be merged with the 74193 which counts to 16 * @@ -31,7 +31,7 @@ #include "../nl_base.h" -#define TTL_74192(_name) \ +#define TTL_74192(_name) \ NET_REGISTER_DEV(74192, _name) #define TTL_74192_DIP(_name) \ diff --git a/src/emu/netlist/devices/nld_74193.h b/src/emu/netlist/devices/nld_74193.h index 92d97c1f6fb..fc2a7de8105 100644 --- a/src/emu/netlist/devices/nld_74193.h +++ b/src/emu/netlist/devices/nld_74193.h @@ -28,7 +28,7 @@ #include "../nl_base.h" -#define TTL_74193(_name) \ +#define TTL_74193(_name) \ NET_REGISTER_DEV(74193, _name) #define TTL_74193_DIP(_name) \ diff --git a/src/emu/netlist/devices/nld_82S16.c b/src/emu/netlist/devices/nld_82S16.c index 4981377d366..047f90f9589 100644 --- a/src/emu/netlist/devices/nld_82S16.c +++ b/src/emu/netlist/devices/nld_82S16.c @@ -32,14 +32,14 @@ NETLIB_UPDATE(82S16) NETLIB_START(82S16) { - register_input("A0", m_A[0]); - register_input("A1", m_A[1]); - register_input("A2", m_A[2]); - register_input("A3", m_A[3]); - register_input("A4", m_A[4]); - register_input("A5", m_A[5]); - register_input("A6", m_A[6]); - register_input("A7", m_A[7]); + register_input("A0", m_A[0]); + register_input("A1", m_A[1]); + register_input("A2", m_A[2]); + register_input("A3", m_A[3]); + register_input("A4", m_A[4]); + register_input("A5", m_A[5]); + register_input("A6", m_A[6]); + register_input("A7", m_A[7]); register_input("CE1Q", m_CE1Q); register_input("CE2Q", m_CE2Q); @@ -63,16 +63,16 @@ NETLIB_RESET(82S16) NETLIB_START(82S16_dip) { - register_input("2", m_A[0]); - register_input("1", m_A[1]); - register_input("15", m_A[2]); - register_input("14", m_A[3]); - register_input("7", m_A[4]); - register_input("9", m_A[5]); - register_input("10", m_A[6]); - register_input("11", m_A[7]); - - register_input("3", m_CE1Q); + register_input("2", m_A[0]); + register_input("1", m_A[1]); + register_input("15", m_A[2]); + register_input("14", m_A[3]); + register_input("7", m_A[4]); + register_input("9", m_A[5]); + register_input("10", m_A[6]); + register_input("11", m_A[7]); + + register_input("3", m_CE1Q); register_input("4", m_CE2Q); register_input("5", m_CE3Q); diff --git a/src/emu/netlist/devices/nld_82S16.h b/src/emu/netlist/devices/nld_82S16.h index 652fbbc13a1..6992e252ca3 100644 --- a/src/emu/netlist/devices/nld_82S16.h +++ b/src/emu/netlist/devices/nld_82S16.h @@ -27,8 +27,7 @@ #include "../nl_base.h" #define TTL_82S16(_name) \ - NET_REGISTER_DEV(82S16, _name) \ - + NET_REGISTER_DEV(82S16, _name) #define TTL_82S16_DIP(_name) \ NET_REGISTER_DEV(82S16_dip, _name) diff --git a/src/emu/netlist/devices/nld_9312.c b/src/emu/netlist/devices/nld_9312.c index 6651848e3a9..2bdaf0714d5 100644 --- a/src/emu/netlist/devices/nld_9312.c +++ b/src/emu/netlist/devices/nld_9312.c @@ -24,7 +24,7 @@ nld_9312::truthtable_t nld_9312::m_ttbl; /* FIXME: Data changes are propagating faster than changing selects A,B,C - * Please refer to data sheet. + * Please refer to data sheet. * This would require a state machine, thus we do not * do this right now. */ diff --git a/src/emu/netlist/devices/nld_9312.h b/src/emu/netlist/devices/nld_9312.h index 98fd0c7177d..677197d00cf 100644 --- a/src/emu/netlist/devices/nld_9312.h +++ b/src/emu/netlist/devices/nld_9312.h @@ -40,8 +40,7 @@ #include "nld_signal.h" #define TTL_9312(_name) \ - NET_REGISTER_DEV(9312, _name) \ - + NET_REGISTER_DEV(9312, _name) //#if (USE_TRUTHTABLE) #include "nld_truthtable.h" NETLIB_TRUTHTABLE(9312, 12, 2, 0); diff --git a/src/emu/netlist/devices/nld_legacy.c b/src/emu/netlist/devices/nld_legacy.c index 31feeef4515..554476c52c3 100644 --- a/src/emu/netlist/devices/nld_legacy.c +++ b/src/emu/netlist/devices/nld_legacy.c @@ -53,7 +53,6 @@ NETLIB_RESET(nicDelay) NETLIB_UPDATE_PARAM(nicDelay) { - } NETLIB_UPDATE(nicDelay) diff --git a/src/emu/netlist/devices/nld_signal.h b/src/emu/netlist/devices/nld_signal.h index 59d9880cc5e..591d45287bc 100644 --- a/src/emu/netlist/devices/nld_signal.h +++ b/src/emu/netlist/devices/nld_signal.h @@ -78,7 +78,7 @@ public: // FIXME: this check is needed because update is called during startup as well //if (m_active == 0 && netlist().use_deactivate()) - // return; + // return; for (int i = 0; i< _numdev; i++) { @@ -152,7 +152,7 @@ public: // FIXME: this check is needed because update is called during startup as well //if (m_active == 0 && netlist().use_deactivate()) - // return; + // return; m_i[0].activate(); m_i[1].activate(); diff --git a/src/emu/netlist/devices/nld_truthtable.h b/src/emu/netlist/devices/nld_truthtable.h index bfb66f827b3..a503a77d856 100644 --- a/src/emu/netlist/devices/nld_truthtable.h +++ b/src/emu/netlist/devices/nld_truthtable.h @@ -186,7 +186,7 @@ public: { // FIXME: this check is needed because update is called during startup as well //if (m_active == 0 && UNEXPECTED(netlist().use_deactivate())) - // return; + // return; UINT32 state = 0; for (int i = 0; i < m_NI; i++) diff --git a/src/emu/netlist/nl_base.c b/src/emu/netlist/nl_base.c index ca66ff57025..c545c29e914 100644 --- a/src/emu/netlist/nl_base.c +++ b/src/emu/netlist/nl_base.c @@ -139,7 +139,7 @@ netlist_base_t::netlist_base_t() : netlist_object_t(NETLIST, GENERIC), m_stop(netlist_time::zero), // FIXME:: Use a parameter to set this on a schematics per schematics basis - m_use_deactivate(USE_DEACTIVE_DEVICE), + m_use_deactivate(USE_DEACTIVE_DEVICE), m_time(netlist_time::zero), m_queue(*this), m_mainclock(NULL), diff --git a/src/emu/netlist/nl_base.h b/src/emu/netlist/nl_base.h index 11267d69aa6..4e83546c184 100644 --- a/src/emu/netlist/nl_base.h +++ b/src/emu/netlist/nl_base.h @@ -1216,7 +1216,7 @@ protected: private: netlist_time m_stop; // target time for current queue processing - bool m_use_deactivate; + bool m_use_deactivate; netlist_time m_time; netlist_queue_t m_queue; diff --git a/src/emu/netlist/nl_config.h b/src/emu/netlist/nl_config.h index 26d5f5620b1..f4154c1f102 100644 --- a/src/emu/netlist/nl_config.h +++ b/src/emu/netlist/nl_config.h @@ -37,7 +37,7 @@ #define USE_DEACTIVE_DEVICE (0) -#define USE_TRUTHTABLE (0) +#define USE_TRUTHTABLE (0) // The following adds about 10% performance ... diff --git a/src/emu/netlist/nl_dice_compat.h b/src/emu/netlist/nl_dice_compat.h index 1b72f93a0b2..552797cfbc9 100644 --- a/src/emu/netlist/nl_dice_compat.h +++ b/src/emu/netlist/nl_dice_compat.h @@ -110,22 +110,21 @@ public: #define CHIP_9602_Mono(_name, _pdesc) \ CHIP(# _name, 9602) \ - NET_C(VCC, _name.16) \ - NET_C(GND, _name.8) \ + NET_C(VCC, _name.16) \ + NET_C(GND, _name.8) \ RES(_name ## _R1, (_pdesc)->r1) \ CAP(_name ## _C1, (_pdesc)->c1) \ RES(_name ## _R2, (_pdesc)->r2) \ NET_C(_name.1, _name ## _C1.1) \ NET_C(_name.2, _name ## _C1.2) \ NET_C(_name.2, _name ## _R1.2) \ - NET_C(VCC, _name ## _R1.1) \ + NET_C(VCC, _name ## _R1.1) \ if (((_pdesc)->c2)>1e-15) { \ CAP(_name ## _C2, (_pdesc)->c2) \ NET_C(_name.15, _name ## _C2.1) \ NET_C(_name.14, _name ## _C2.2) }\ NET_C(_name.14, _name ## _R2.2) \ - NET_C(VCC, _name ## _R2.1) \ - + NET_C(VCC, _name ## _R2.1) #define CHIP_SERIES_RC(_name, _pdesc) \ RES(_name ## _R, (_pdesc)->r) \ CAP(_name ## _C, (_pdesc)->c) \ @@ -153,7 +152,7 @@ public: ALIAS(_name.3, _name.QQ) /* FIXME: Alternative implementation using capacitor. - * This is a transitional implementation + * This is a transitional implementation */ inline int CAPACITOR_tc(const double c, const double r) @@ -166,7 +165,6 @@ inline int CAPACITOR_tc(const double c, const double r) #define CHIP_CAPACITOR(_name, _pdesc) \ NETDEV_DELAY(_name) \ NETDEV_PARAMI(_name, L_TO_H, CAPACITOR_tc((_pdesc)->c, (_pdesc)->r)) \ - NETDEV_PARAMI(_name, H_TO_HL, CAPACITOR_tc((_pdesc)->c, (_pdesc)->r)) \ - + NETDEV_PARAMI(_name, H_TO_HL, CAPACITOR_tc((_pdesc)->c, (_pdesc)->r)) #endif /* NL_DICE_COMPAT_H_ */ diff --git a/src/emu/sound/discrete.h b/src/emu/sound/discrete.h index 621ad77749c..ef674da5e8d 100644 --- a/src/emu/sound/discrete.h +++ b/src/emu/sound/discrete.h @@ -4128,7 +4128,7 @@ enum { #define IS_VALUE_A_NODE(val) (((val) > NODE_START) && ((val) <= NODE_END)) // Optional node such as used in CR_FILTER -#define OPT_NODE(val) (int) val +#define OPT_NODE(val) (int) val /************************************* * * Enumerated values for Node types diff --git a/src/emu/sound/es1373.c b/src/emu/sound/es1373.c index af4054e241e..8b4a65456d4 100644 --- a/src/emu/sound/es1373.c +++ b/src/emu/sound/es1373.c @@ -2,7 +2,7 @@ #define LOG_ES (0) #define LOG_ES_REG (0) -#define LOG_ES_FILE (0) +#define LOG_ES_FILE (0) static MACHINE_CONFIG_FRAGMENT( es1373 ) @@ -122,7 +122,6 @@ void es1373_device::device_timer(emu_timer &timer, device_timer_id tid, int para //------------------------------------------------- void es1373_device::sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) { - if (m_dac1.enable) { logerror("%s: sound_stream_update DAC1 not implemented yet\n", tag()); } diff --git a/src/emu/sound/es1373.h b/src/emu/sound/es1373.h index ad30b0d8c67..4436c9ffdc0 100644 --- a/src/emu/sound/es1373.h +++ b/src/emu/sound/es1373.h @@ -66,10 +66,10 @@ #define SCTRL_P2_S_MASK 0x0000000C #define SCTRL_P1_S_MASK 0x00000003 -#define SCTRL_8BIT_MONO 0x0 -#define SCTRL_8BIT_STEREO 0x1 -#define SCTRL_16BIT_MONO 0x2 -#define SCTRL_16BIT_STEREO 0x3 +#define SCTRL_8BIT_MONO 0x0 +#define SCTRL_8BIT_STEREO 0x1 +#define SCTRL_16BIT_MONO 0x2 +#define SCTRL_16BIT_STEREO 0x3 #define ES_PCI_READ 0 #define ES_PCI_WRITE 1 diff --git a/src/emu/sound/l7a1045_l6028_dsp_a.c b/src/emu/sound/l7a1045_l6028_dsp_a.c index d53e2085d4a..8d8effe6d2a 100644 --- a/src/emu/sound/l7a1045_l6028_dsp_a.c +++ b/src/emu/sound/l7a1045_l6028_dsp_a.c @@ -1,84 +1,84 @@ /*************************************************************************** L7A1045 L6028 DSP-A - (QFP120 package) + (QFP120 package) - this is the audio chip used on the following - SNK Hyper NeoGeo 64 (arcade platform) - AKAI MPC3000 (synth) + this is the audio chip used on the following + SNK Hyper NeoGeo 64 (arcade platform) + AKAI MPC3000 (synth) - both are driven by a V53, the MPC3000 isn't dumped. + both are driven by a V53, the MPC3000 isn't dumped. - appears to write a register number and channel/voice using - l7a1045_sound_select_w (offset 0) - format: + appears to write a register number and channel/voice using + l7a1045_sound_select_w (offset 0) + format: - ---- rrrr ---c cccc - r = register, c = channel + ---- rrrr ---c cccc + r = register, c = channel - the channel select appears to address 32 different voices (5-bits) - the register select appears to use 4-bits with 0x0 to 0xa being valid + the channel select appears to address 32 different voices (5-bits) + the register select appears to use 4-bits with 0x0 to 0xa being valid - the registers data is written / read using offsets 1,2,3 after - setting the register + channel, this gives 3 16-bit values for - each register. + the registers data is written / read using offsets 1,2,3 after + setting the register + channel, this gives 3 16-bit values for + each register. - register format: + register format: - offset 3 offset 2 offset 1 - fedcba9876543210 | fedcba9876543210 | fedcba9876543210 + offset 3 offset 2 offset 1 + fedcba9876543210 | fedcba9876543210 | fedcba9876543210 - 0 ---------------- ---------------- ---------------- + 0 ---------------- ---------------- ---------------- - 1 ---------------- ---------------- ---------------- + 1 ---------------- ---------------- ---------------- - 2 ---------------- ---------------- ---------------- + 2 ---------------- ---------------- ---------------- - 3 ---------------- ---------------- ---------------- + 3 ---------------- ---------------- ---------------- - 4 ---------------- ---------------- ---------------- + 4 ---------------- ---------------- ---------------- - 5 ---------------- ---------------- ---------------- + 5 ---------------- ---------------- ---------------- - 6 ---------------- ---------------- ---------------- + 6 ---------------- ---------------- ---------------- - 7 ---------------- ---------------- llllllllrrrrrrrr left/right volume + 7 ---------------- ---------------- llllllllrrrrrrrr left/right volume - 8 ---------------- ---------------- ---------------- (read only?) + 8 ---------------- ---------------- ---------------- (read only?) - 9 ---------------- ---------------- ---------------- (read only?) + 9 ---------------- ---------------- ---------------- (read only?) - a ---------------- ---------------- ---------------- + a ---------------- ---------------- ---------------- - Registers are not yet understood. + Registers are not yet understood. - probably sample start, end, loop positions, panning etc. - like CPS3, Qsound etc. + probably sample start, end, loop positions, panning etc. + like CPS3, Qsound etc. - case 0x00: - case 0x01: - case 0x02: - case 0x03: // 00003fffffff (startup only?) - case 0x04: // doesn't use 6 - case 0x05: // 00003fffffff (mostly, often) - case 0x06: // 00007ff0ffff mostly - case 0x07: // 0000000f0708 etc. (low values) - case 0x08: // doesn't write to 2/4/6 with this set?? - case 0x09: // doesn't write to 2/4/6 with this set?? - case 0x0a: // random looking values + case 0x00: + case 0x01: + case 0x02: + case 0x03: // 00003fffffff (startup only?) + case 0x04: // doesn't use 6 + case 0x05: // 00003fffffff (mostly, often) + case 0x06: // 00007ff0ffff mostly + case 0x07: // 0000000f0708 etc. (low values) + case 0x08: // doesn't write to 2/4/6 with this set?? + case 0x09: // doesn't write to 2/4/6 with this set?? + case 0x0a: // random looking values - Some of the other ports on the HNG64 sound CPU may also be tied - to this chip, this isn't yet clear. - Port $8 bit 8 is keyon, low byte is sound status related (masked with 0x7f) + Some of the other ports on the HNG64 sound CPU may also be tied + to this chip, this isn't yet clear. + Port $8 bit 8 is keyon, low byte is sound status related (masked with 0x7f) - Sample data format TBA + Sample data format TBA + + TODO: + - Sample format needs to be double checked; + - Octave Control/BPM/Pitch, right now XRally Network BGM wants 66150 Hz which is definitely too fast for Terry Bogard speech; + - Key Off; + - ADSR (registers 2 & 4?); - TODO: - - Sample format needs to be double checked; - - Octave Control/BPM/Pitch, right now XRally Network BGM wants 66150 Hz which is definitely too fast for Terry Bogard speech; - - Key Off; - - ADSR (registers 2 & 4?); - ***************************************************************************/ #include "emu.h" @@ -132,7 +132,7 @@ void l7a1045_sound_device::sound_stream_update(sound_stream &stream, stream_samp /* Clear the buffers */ memset(outputs[0], 0, samples*sizeof(*outputs[0])); memset(outputs[1], 0, samples*sizeof(*outputs[1])); - + for (int i = 0; i < 32; i++) { if (m_key & (1 << i)) @@ -142,7 +142,7 @@ void l7a1045_sound_device::sound_stream_update(sound_stream &stream, stream_samp UINT32 start = vptr->start; UINT32 end = vptr->end; UINT32 step = 0x400; - + UINT32 pos = vptr->pos; UINT32 frac = vptr->frac; @@ -150,7 +150,7 @@ void l7a1045_sound_device::sound_stream_update(sound_stream &stream, stream_samp { INT32 sample; UINT8 data; - + pos += (frac >> 12); frac &= 0xfff; @@ -205,7 +205,7 @@ READ16_MEMBER( l7a1045_sound_device::l7a1045_sound_r ) printf("sound_select_r?\n"); else return sound_data_r(space,offset -1,mem_mask); - + return 0xffff; } @@ -238,7 +238,7 @@ WRITE16_MEMBER(l7a1045_sound_device::sound_data_w) l7a1045_voice *vptr = &m_voice[m_audiochannel]; //if(m_audioregister != 0 && m_audioregister != 1 && m_audioregister != 7) - // printf("%04x %04x (%04x %04x)\n",offset,data,m_audioregister,m_audiochannel); + // printf("%04x %04x (%04x %04x)\n",offset,data,m_audioregister,m_audiochannel); m_audiodat[m_audioregister][m_audiochannel].dat[offset] = data; @@ -277,9 +277,9 @@ WRITE16_MEMBER(l7a1045_sound_device::sound_data_w) vptr->end &= m_rom_size - 1; } - + break; - + case 0x07: vptr->r_volume = (m_audiodat[m_audioregister][m_audiochannel].dat[0] & 0xff); @@ -302,11 +302,11 @@ READ16_MEMBER(l7a1045_sound_device::sound_data_r) switch(m_audioregister) { - case 0x00: + case 0x00: { UINT32 current_addr; UINT16 res; - + current_addr = vptr->start + vptr->pos; if(offset == 0) res = (current_addr & 0xf) << 12; // TODO: frac @@ -314,11 +314,11 @@ READ16_MEMBER(l7a1045_sound_device::sound_data_r) res = (current_addr & 0xffff0) >> 4; else res = (current_addr & 0xf00000) >> 20; - + return res; } } - + return 0; } @@ -333,16 +333,14 @@ WRITE16_MEMBER(l7a1045_sound_device::sound_status_w) { printf("%08x START\n",vptr->start); printf("%08x END\n",vptr->end); - + for(int i=0;i<0x10;i++) printf("%02x (%02x) = %04x%04x%04x\n",m_audiochannel,i,m_audiodat[i][m_audiochannel].dat[2],m_audiodat[i][m_audiochannel].dat[1],m_audiodat[i][m_audiochannel].dat[0]); } #endif - + vptr->frac = 0; vptr->pos = 0; m_key |= 1 << m_audiochannel; } } - - diff --git a/src/emu/sound/l7a1045_l6028_dsp_a.h b/src/emu/sound/l7a1045_l6028_dsp_a.h index 1754556e855..da0cbb41c13 100644 --- a/src/emu/sound/l7a1045_l6028_dsp_a.h +++ b/src/emu/sound/l7a1045_l6028_dsp_a.h @@ -30,7 +30,7 @@ public: l7a1045_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); ~l7a1045_sound_device() { } -// void set_base(INT8* base) { m_base = base; } +// void set_base(INT8* base) { m_base = base; } DECLARE_WRITE16_MEMBER( l7a1045_sound_w ); DECLARE_READ16_MEMBER( l7a1045_sound_r ); diff --git a/src/emu/video.c b/src/emu/video.c index bee4f24282d..55e596d36bc 100644 --- a/src/emu/video.c +++ b/src/emu/video.c @@ -1215,7 +1215,7 @@ file_error video_manager::open_next(emu_file &file, const char *extension) for (int seq = 0; ; seq++) { // build up the filename - fname.assign(snapstr); + fname.assign(snapstr); strprintf(seqtext, "%04d", seq); strreplace(fname, "%i", seqtext.c_str()); diff --git a/src/emu/video/clgd542x.c b/src/emu/video/clgd542x.c index 30b96110290..0bee39533cb 100644 --- a/src/emu/video/clgd542x.c +++ b/src/emu/video/clgd542x.c @@ -1,6 +1,6 @@ /* - Cirrus Logic GD542x/3x video chipsets + Cirrus Logic GD542x/3x video chipsets */ @@ -126,7 +126,7 @@ void cirrus_gd5428_device::device_reset() m_blt_source = m_blt_dest = m_blt_source_current = m_blt_dest_current = 0; memset(m_ext_palette, 0, sizeof(m_ext_palette)); m_ext_palette_enabled = false; -// m_ext_palette[15].red = m_ext_palette[15].green = m_ext_palette[15].blue = 0xff; // default? Win3.1 doesn't seem to touch the extended DAC, or at least, it enables it, then immediately disables it then sets a palette... +// m_ext_palette[15].red = m_ext_palette[15].green = m_ext_palette[15].blue = 0xff; // default? Win3.1 doesn't seem to touch the extended DAC, or at least, it enables it, then immediately disables it then sets a palette... } UINT32 cirrus_gd5428_device::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) @@ -201,7 +201,7 @@ UINT32 cirrus_gd5428_device::screen_update(screen_device &screen, bitmap_rgb32 & } } } - return 0; + return 0; } void cirrus_gd5428_device::cirrus_define_video_mode() @@ -209,7 +209,7 @@ void cirrus_gd5428_device::cirrus_define_video_mode() UINT8 divisor = 1; float clock; UINT8 clocksel = (vga.miscellaneous_output & 0xc) >> 2; - + svga.rgb8_en = 0; svga.rgb15_en = 0; svga.rgb16_en = 0; @@ -226,7 +226,7 @@ void cirrus_gd5428_device::cirrus_define_video_mode() clock = 14.31818f * ((float)numerator / ((float)denominator * mul)); clock *= 1000000; } - + if (!gc_locked && (vga.sequencer.data[0x07] & 0x01)) { switch(vga.sequencer.data[0x07] & 0x0E) @@ -247,7 +247,7 @@ UINT16 cirrus_gd5428_device::offset() if (svga.rgb8_en == 1) // guess off <<= 2; -// popmessage("Offset: %04x %s %s ** -- actual: %04x",vga.crtc.offset,vga.crtc.dw?"DW":"--",vga.crtc.word_mode?"BYTE":"WORD",off); +// popmessage("Offset: %04x %s %s ** -- actual: %04x",vga.crtc.offset,vga.crtc.dw?"DW":"--",vga.crtc.word_mode?"BYTE":"WORD",off); return off; } @@ -259,7 +259,7 @@ void cirrus_gd5428_device::start_bitblt() m_blt_source_current = m_blt_source; m_blt_dest_current = m_blt_dest; - + for(y=0;y<m_blt_height;y++) { for(x=0;x<m_blt_width;x++) @@ -289,13 +289,13 @@ void cirrus_gd5428_device::copy_pixel() { UINT8 src = vga.memory[m_blt_source_current % vga.svga_intf.vram_size]; UINT8 dst = vga.memory[m_blt_dest_current % vga.svga_intf.vram_size]; - + if(m_blt_mode & 0x40) // enable 8x8 pattern { if(m_blt_mode & 0x80) // colour expand src = (vga.memory[m_blt_source % vga.svga_intf.vram_size] >> (abs((int)(m_blt_source_current - m_blt_source)) % 8)) & 0x01 ? 0xff : 0x00; } - + switch(m_blt_rop) { case 0x00: // BLACK @@ -728,7 +728,7 @@ READ8_MEMBER(cirrus_gd5428_device::port_03c0_r) vga.dac.read_index++; } } - } + } break; case 0x0f: res = cirrus_gc_reg_read(vga.gc.index); @@ -767,9 +767,9 @@ WRITE8_MEMBER(cirrus_gd5428_device::port_03c0_w) break; } vga.dac.dirty=1; - if (vga.dac.state==3) + if (vga.dac.state==3) { - vga.dac.state=0; + vga.dac.state=0; vga.dac.write_index++; } } @@ -985,14 +985,14 @@ READ8_MEMBER(cirrus_gd5428_device::mem_r) // Is the display address adjusted automatically when not using Chain-4 addressing? The GD542x BIOS doesn't do it, but Virtual Pool expects it. if(!(vga.sequencer.data[4] & 0x8)) - addr <<= 2; + addr <<= 2; if(svga.rgb8_en || svga.rgb15_en || svga.rgb16_en || svga.rgb24_en) { UINT8 data = 0; if(gc_mode_ext & 0x01) { - if(offset & 0x10000) + if(offset & 0x10000) return 0; if(offset < 0x8000) offset &= 0x7fff; @@ -1069,7 +1069,7 @@ READ8_MEMBER(cirrus_gd5428_device::mem_r) { // TODO: Lines up in 16-colour mode, likely different for 256-colour modes (docs say video addresses are shifted right 3 places) UINT8 i,data; -// UINT8 bits = ((gc_mode_ext & 0x08) && (vga.gc.write_mode == 1)) ? 8 : 4; +// UINT8 bits = ((gc_mode_ext & 0x08) && (vga.gc.write_mode == 1)) ? 8 : 4; data = 0; //printf("%08x\n",offset); @@ -1119,11 +1119,11 @@ WRITE8_MEMBER(cirrus_gd5428_device::mem_w) // Is the display address adjusted automatically when using Chain-4 addressing? The GD542x BIOS doesn't do it, but Virtual Pool expects it. if(!(vga.sequencer.data[4] & 0x8)) - addr <<= 2; + addr <<= 2; if(svga.rgb8_en || svga.rgb15_en || svga.rgb16_en || svga.rgb24_en) { - if(offset & 0x10000) + if(offset & 0x10000) return; if(gc_mode_ext & 0x01) { @@ -1163,7 +1163,7 @@ WRITE8_MEMBER(cirrus_gd5428_device::mem_w) } return; } - + if(vga.sequencer.data[4] & 0x8) vga.memory[(offset+addr) % vga.svga_intf.vram_size] = data; else @@ -1208,7 +1208,7 @@ WRITE8_MEMBER(cirrus_gd5428_device::mem_w) { // TODO: Lines up in 16-colour mode, likely different for 256-colour modes (docs say video addresses are shifted right 3 places) UINT8 i; -// UINT8 bits = ((gc_mode_ext & 0x08) && (vga.gc.write_mode == 1)) ? 8 : 4; +// UINT8 bits = ((gc_mode_ext & 0x08) && (vga.gc.write_mode == 1)) ? 8 : 4; for(i=0;i<4;i++) { @@ -1227,4 +1227,3 @@ WRITE8_MEMBER(cirrus_gd5428_device::mem_w) } } } - diff --git a/src/emu/video/clgd542x.h b/src/emu/video/clgd542x.h index d78fb44b85c..9288abcf669 100644 --- a/src/emu/video/clgd542x.h +++ b/src/emu/video/clgd542x.h @@ -1,6 +1,6 @@ /* - Cirrus Logic GD542x/3x video chipsets + Cirrus Logic GD542x/3x video chipsets */ @@ -39,11 +39,11 @@ protected: UINT8 gc_bank_1; bool gc_locked; UINT8 m_lock_reg; - + UINT8 m_cr19; UINT8 m_cr1a; UINT8 m_cr1b; - + // hardware cursor UINT16 m_cursor_x; UINT16 m_cursor_y; @@ -64,13 +64,13 @@ protected: UINT16 m_blt_width; UINT32 m_blt_source_current; UINT32 m_blt_dest_current; - + UINT8 m_scratchpad1; UINT8 m_scratchpad2; UINT8 m_scratchpad3; UINT8 m_vclk_num[4]; UINT8 m_vclk_denom[4]; - + inline UINT8 cirrus_vga_latch_write(int offs, UINT8 data); private: void cirrus_define_video_mode(); @@ -80,7 +80,7 @@ private: void cirrus_gc_reg_write(UINT8 index, UINT8 data); UINT8 cirrus_crtc_reg_read(UINT8 index); void cirrus_crtc_reg_write(UINT8 index, UINT8 data); - + void start_bitblt(); void copy_pixel(); }; @@ -96,4 +96,3 @@ protected: // device type definition extern const device_type CIRRUS_GD5428; extern const device_type CIRRUS_GD5430; - diff --git a/src/emu/video/pc_vga.c b/src/emu/video/pc_vga.c index 382e3dd33f9..82302bef6ec 100644 --- a/src/emu/video/pc_vga.c +++ b/src/emu/video/pc_vga.c @@ -5547,5 +5547,3 @@ READ16_MEMBER(mach8_device::mach8_config2_r) { return 0x0002; } - - diff --git a/src/emu/video/pc_vga.h b/src/emu/video/pc_vga.h index 6d7fada64c5..c88b995ecab 100644 --- a/src/emu/video/pc_vga.h +++ b/src/emu/video/pc_vga.h @@ -175,8 +175,8 @@ protected: /**/ UINT8 sldiv; /**/ UINT8 map14; /**/ UINT8 map13; - /**/ UINT8 irq_clear; - /**/ UINT8 irq_disable; + /**/ UINT8 irq_clear; + /**/ UINT8 irq_disable; } crtc; struct |
