summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
author Robbbert <Robbbert@users.noreply.github.com>2018-10-30 23:16:38 +1100
committer Robbbert <Robbbert@users.noreply.github.com>2018-10-30 23:16:38 +1100
commit0340e8ac2cea61bce122b8e44fb8b64f86bc804c (patch)
treead1649c28664f31eb65dc29265bbd495bc33f830 /src
parent9a49527058450fa61c2665937002dd506632f154 (diff)
parentfc726060143d454c838fba9c82ce830c63a008c0 (diff)
Merge remote-tracking branch 'upstream/release0203'
Diffstat (limited to 'src')
-rw-r--r--src/devices/bus/bbc/exp/mertec.h2
-rw-r--r--src/devices/bus/hp_dio/hp98265a.cpp10
-rw-r--r--src/devices/bus/hp_dio/hp_dio.cpp4
-rw-r--r--src/devices/bus/hp_hil/hlekbd.cpp4
-rw-r--r--src/devices/bus/hp_hil/hlemouse.cpp2
-rw-r--r--src/devices/cpu/m6502/oxavix.lst6
-rw-r--r--src/devices/cpu/m6502/oxavix2000.lst6
-rw-r--r--src/devices/cpu/m6502/xavix.h6
-rw-r--r--src/devices/cpu/m6502/xavix2000.cpp80
-rw-r--r--src/devices/cpu/m6502/xavix2000.h2
-rw-r--r--src/devices/cpu/m68000/m68kdasm.cpp9
-rw-r--r--src/devices/cpu/m68000/m68kmmu.h119
-rw-r--r--src/devices/cpu/sparc/mb86901.cpp190
-rw-r--r--src/devices/cpu/sparc/sparcdefs.h2
-rw-r--r--src/devices/cpu/unsp/unsp.cpp10
-rw-r--r--src/devices/cpu/unsp/unsp.h12
-rw-r--r--src/devices/cpu/unsp/unspdasm.cpp12
-rw-r--r--src/devices/cpu/unsp/unspdasm.h8
-rw-r--r--src/devices/machine/am9517a.cpp25
-rw-r--r--src/devices/machine/mb87030.cpp8
-rw-r--r--src/devices/machine/msm58321.cpp11
-rw-r--r--src/devices/machine/scc2698b.cpp186
-rw-r--r--src/devices/machine/scc2698b.h95
-rw-r--r--src/devices/machine/smioc.cpp104
-rw-r--r--src/devices/machine/smioc.h2
-rw-r--r--src/devices/machine/spg2xx.cpp70
-rw-r--r--src/devices/machine/spg2xx.h310
-rw-r--r--src/devices/machine/sun4c_mmu.cpp40
-rw-r--r--src/devices/machine/sun4c_mmu.h4
-rw-r--r--src/devices/machine/tms9914.cpp31
-rw-r--r--src/devices/sound/pokey.cpp44
-rw-r--r--src/devices/video/dp8350.cpp36
-rw-r--r--src/devices/video/dp8350.h12
-rw-r--r--src/emu/dirtc.cpp4
-rw-r--r--src/emu/emuopts.cpp2
-rw-r--r--src/mame/drivers/8080bw.cpp19
-rw-r--r--src/mame/drivers/alg.cpp42
-rw-r--r--src/mame/drivers/atetris.cpp4
-rw-r--r--src/mame/drivers/brkthru.cpp4
-rw-r--r--src/mame/drivers/combatsc.cpp2
-rw-r--r--src/mame/drivers/cps1.cpp62
-rw-r--r--src/mame/drivers/cps2.cpp37
-rw-r--r--src/mame/drivers/cps3.cpp14
-rw-r--r--src/mame/drivers/crystal.cpp34
-rw-r--r--src/mame/drivers/ddragon.cpp16
-rw-r--r--src/mame/drivers/fcrash.cpp2
-rw-r--r--src/mame/drivers/hapyfish.cpp16
-rw-r--r--src/mame/drivers/holeland.cpp6
-rw-r--r--src/mame/drivers/hp9825.cpp8
-rw-r--r--src/mame/drivers/hp9k_3xx.cpp4
-rw-r--r--src/mame/drivers/ibm6580.cpp2
-rw-r--r--src/mame/drivers/itgamble.cpp14
-rw-r--r--src/mame/drivers/ltd.cpp16
-rw-r--r--src/mame/drivers/mpu4misc.cpp8
-rw-r--r--src/mame/drivers/mwarr.cpp2
-rw-r--r--src/mame/drivers/namcond1.cpp16
-rw-r--r--src/mame/drivers/namcos22.cpp185
-rw-r--r--src/mame/drivers/namcos23.cpp6
-rw-r--r--src/mame/drivers/pacman.cpp44
-rw-r--r--src/mame/drivers/peplus.cpp17
-rw-r--r--src/mame/drivers/phoenix.cpp1
-rw-r--r--src/mame/drivers/r9751.cpp15
-rw-r--r--src/mame/drivers/rainbow.cpp2
-rw-r--r--src/mame/drivers/scobra.cpp2
-rw-r--r--src/mame/drivers/segas32.cpp3
-rw-r--r--src/mame/drivers/snesb.cpp42
-rw-r--r--src/mame/drivers/snk.cpp7
-rw-r--r--src/mame/drivers/splus.cpp21
-rw-r--r--src/mame/drivers/supertnk.cpp34
-rw-r--r--src/mame/drivers/tecmo16.cpp2
-rw-r--r--src/mame/drivers/tehkanwc.cpp2
-rw-r--r--src/mame/drivers/toypop.cpp87
-rw-r--r--src/mame/drivers/twins.cpp2
-rw-r--r--src/mame/drivers/vgmplay.cpp4
-rw-r--r--src/mame/drivers/vii.cpp28
-rw-r--r--src/mame/drivers/xavix.cpp14
-rw-r--r--src/mame/includes/bbc.h2
-rw-r--r--src/mame/includes/ddragon.h1
-rw-r--r--src/mame/includes/namcos22.h13
-rw-r--r--src/mame/includes/xavix.h4
-rw-r--r--src/mame/layout/hp9825.lay69
-rw-r--r--src/mame/layout/hp9k_3xx.lay6
-rw-r--r--src/mame/layout/yosakdon.lay62
-rw-r--r--src/mame/machine/bbc.cpp4
-rw-r--r--src/mame/machine/ibm6580_fdc.cpp4
-rw-r--r--src/mame/machine/kb_poisk1.h2
-rw-r--r--src/mame/machine/ms7004.cpp92
-rw-r--r--src/mame/machine/namcos2.cpp2
-rw-r--r--src/mame/machine/xavix.cpp4
-rw-r--r--src/mame/mame.lst11
-rw-r--r--src/mame/video/cps1.cpp2
-rw-r--r--src/mame/video/edevices.cpp34
-rw-r--r--src/mame/video/flkatck.cpp2
-rw-r--r--src/mame/video/k007121.cpp6
-rw-r--r--src/mame/video/namco_c355spr.cpp4
-rw-r--r--src/mame/video/namco_c355spr.h3
-rw-r--r--src/mame/video/xavix.cpp56
-rw-r--r--src/osd/modules/render/d3d/d3dhlsl.cpp21
-rw-r--r--src/osd/windows/window.cpp2
-rw-r--r--src/tools/unidasm.cpp2
100 files changed, 1430 insertions, 1292 deletions
diff --git a/src/devices/bus/bbc/exp/mertec.h b/src/devices/bus/bbc/exp/mertec.h
index cb39167506d..4e117fe28cf 100644
--- a/src/devices/bus/bbc/exp/mertec.h
+++ b/src/devices/bus/bbc/exp/mertec.h
@@ -4,7 +4,7 @@
Mertec Compact Companion
- http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Mertec_CompactComp.html
+ http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Mertec_CompactComp.html
**********************************************************************/
diff --git a/src/devices/bus/hp_dio/hp98265a.cpp b/src/devices/bus/hp_dio/hp98265a.cpp
index 8146b2c16da..b944661a851 100644
--- a/src/devices/bus/hp_dio/hp98265a.cpp
+++ b/src/devices/bus/hp_dio/hp98265a.cpp
@@ -18,13 +18,12 @@
DEFINE_DEVICE_TYPE_NS(HPDIO_98265A, bus::hp_dio, dio16_98265a_device, "hp98265a", "HP98265A SCSI S16 Interface")
-namespace bus {
- namespace hp_dio {
+namespace bus { namespace hp_dio {
static void scsi_devices(device_slot_interface &device)
{
- device.option_add("cdrom", NSCSI_CDROM);
- device.option_add("harddisk", NSCSI_HARDDISK);
+ device.option_add("cdrom", NSCSI_CDROM);
+ device.option_add("harddisk", NSCSI_HARDDISK);
}
void dio16_98265a_device::mb87030_scsi_adapter(device_t *device)
@@ -299,5 +298,4 @@ WRITE_LINE_MEMBER(dio16_98265a_device::dmar0_w)
}
-}
-}
+} } // namespace bus::hp_dio
diff --git a/src/devices/bus/hp_dio/hp_dio.cpp b/src/devices/bus/hp_dio/hp_dio.cpp
index c90a1e2c83a..035f3ea2b5c 100644
--- a/src/devices/bus/hp_dio/hp_dio.cpp
+++ b/src/devices/bus/hp_dio/hp_dio.cpp
@@ -257,11 +257,11 @@ void dio16_device::install_memory(offs_t start, offs_t end,
switch (m_prgwidth) {
case 16:
m_prgspace->install_readwrite_handler(start, end, rhandler,
- whandler);
+ whandler);
break;
case 32:
m_prgspace->install_readwrite_handler(start, end, rhandler,
- whandler, 0xffffffff);
+ whandler, 0xffffffff);
break;
default:
fatalerror("DIO: Bus width %d not supported\n", m_prgwidth);
diff --git a/src/devices/bus/hp_hil/hlekbd.cpp b/src/devices/bus/hp_hil/hlekbd.cpp
index 4771243bef9..cb4a0dbb529 100644
--- a/src/devices/bus/hp_hil/hlekbd.cpp
+++ b/src/devices/bus/hp_hil/hlekbd.cpp
@@ -475,7 +475,7 @@ int hle_hp_ipc_device::hil_poll()
return frames;
m_hp_hil_mlc->hil_write(m_device_id16 | 0x40); // Keycode Set 1, no coordinate data
- while (!m_fifo.empty()) {
+ while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
@@ -490,7 +490,7 @@ int hle_hp_itf_device::hil_poll()
LOG("KBD HAVE DATA\n");
frames++;
m_hp_hil_mlc->hil_write(m_device_id16 | 0x40); // Keycode Set 1, no coordinate data
- while (!m_fifo.empty()) {
+ while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
diff --git a/src/devices/bus/hp_hil/hlemouse.cpp b/src/devices/bus/hp_hil/hlemouse.cpp
index 9fc6c9db985..d61f9143eff 100644
--- a/src/devices/bus/hp_hil/hlemouse.cpp
+++ b/src/devices/bus/hp_hil/hlemouse.cpp
@@ -68,7 +68,7 @@ int hle_hp_46060b_device::hil_poll()
frames+=2;
}
- while (!m_fifo.empty()) {
+ while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
diff --git a/src/devices/cpu/m6502/oxavix.lst b/src/devices/cpu/m6502/oxavix.lst
index 5cb5fd62349..d8b811a18a8 100644
--- a/src/devices/cpu/m6502/oxavix.lst
+++ b/src/devices/cpu/m6502/oxavix.lst
@@ -64,7 +64,7 @@ brk_xav_imp
else
{
PC = read_arg(0xfffa);
- PC = set_h(PC, read_arg(0xfffb));
+ PC = set_h(PC, read_arg(0xfffb));
}
}
@@ -86,7 +86,7 @@ brk_xav_imp
else
{
PC = read_arg(0xfffe);
- PC = set_h(PC, read_arg(0xffff));
+ PC = set_h(PC, read_arg(0xffff));
}
}
@@ -122,4 +122,4 @@ xavlda_idy
}
A = read_special(TMP+Y);
set_nz(A);
- prefetch(); \ No newline at end of file
+ prefetch();
diff --git a/src/devices/cpu/m6502/oxavix2000.lst b/src/devices/cpu/m6502/oxavix2000.lst
index 3171c62c915..12be0a7868c 100644
--- a/src/devices/cpu/m6502/oxavix2000.lst
+++ b/src/devices/cpu/m6502/oxavix2000.lst
@@ -141,7 +141,7 @@ adcl3_acc
read_pc_noinc();
do_adc((m_l & 0xff000000) >> 24);
prefetch();
-
+
stal0_acc
read_pc_noinc();
m_l = (m_l & 0xffffff00) | (A & 0xff); // TODO: flags
@@ -241,7 +241,7 @@ lpa1_acc
read_pc_noinc();
A = (m_pa & 0x00ff00) >> 8; // TODO: Flags?
prefetch();
-
+
spa2_acc
read_pc_noinc();
m_pa = (m_pa & 0x00ffff) | (A << 16); // TODO: Flags?
@@ -341,7 +341,7 @@ cmppa_imp
sbcpa_imp
do_sbc(read_full_data_sp(m_pa+Y));
prefetch();
-
+
orapb_imp
fatalerror("unhandled opcode %02x%04x: %02x\n", m_codebank, PPC, inst_state);
read_pc_noinc();
diff --git a/src/devices/cpu/m6502/xavix.h b/src/devices/cpu/m6502/xavix.h
index ce71d77cb7e..77b199d754f 100644
--- a/src/devices/cpu/m6502/xavix.h
+++ b/src/devices/cpu/m6502/xavix.h
@@ -92,11 +92,11 @@ protected:
virtual space_config_vector memory_space_config() const override;
address_space_config m_special_data_config;
- address_space *m_special_data_space;
+ address_space *m_special_data_space;
address_space_config m_lowbus_config;
address_space_config m_extbus_config;
- address_space *m_lowbus_space;
- address_space *m_extbus_space;
+ address_space *m_lowbus_space;
+ address_space *m_extbus_space;
uint8_t read_special(uint16_t adr);
diff --git a/src/devices/cpu/m6502/xavix2000.cpp b/src/devices/cpu/m6502/xavix2000.cpp
index 8580867d3ed..fe173150de0 100644
--- a/src/devices/cpu/m6502/xavix2000.cpp
+++ b/src/devices/cpu/m6502/xavix2000.cpp
@@ -25,51 +25,51 @@
some of the documented but 'undocumented' opcodes on the 6502 to have additonal
meaning for one specific function on startup
- this just seems to be some very buggy checksum code where the games don't even care about the result...
- (actually it looks like some games might be using it as a PRNG seed?)
-
- a is 80 when entering here?
-
- 01BC37: A0 3F ldy #$3f
- 01BC39: B2 clr a // clear acculuator
- 01BC3A: 1B spa0 a // store 'accumulator' into byte 0 of PA 'address' register
- 01BC3B: 9B spa2 a // store 'accumulator' into byte 2 of PA 'address' register
-
- -- loop point 2
- 01BC3C: 98 tya // y -> a (3f on first run of loop)
- 01BC3D: 5B spa1 a // store 'accumulator' into byte 1 of PA 'address' register (003f00 on first loop?)
-
- -- loop point 1
- 01BC3E: A3 ldal0 a // read byte 0 of 32-bit 'long' register into accumulator
- 01BC3F: 73 adcpa // adc ($Address PA), y
- 01BC40: 83 stal0 a // store accumulator back in byte 0 of 32-bit 'long' register (even byte checksum?)
- 01BC41: FB incpa // increase 'address' register PA
- 01BC42: A7 ldal1 a // read byte 1 of 32-bit 'long' register into accumulator
- 01BC43: 73 adcpa // adc ($Address PA), y
- 01BC44: 87 stal1 a // store accumulator back in byte 0 of 32-bit 'long' register (odd byte checksum?)
- 01BC45: FB incpa // increase 'address' register PA
- 01BC46: D0 F6 bne $1bc3e // (branch based on PA increase, so PA must set flags?, probably overflows after 0xffff if upper byte is 'bank'? or at 0xff if this really is a mirror of the function below
-
- 01BC48: 88 dey // decrease y, which contained 3f at the start
- 01BC49: 10 F1 bpl $1bc3c // branch back to loop point 2 to reload counter
-
- // contains the odd byte checksum once we drop out the loop
- 01BC4B: 8D FB 00 sta $00fb // store it in zero page memory
- 01BC4E: A3 ldal0 a // get the even byte checksum from byte 0 of 32-bit 'long' register
- 01BC4F: 8D FA 00 sta $00fa // store it in zero page memory
- 01BC52: 07 oral1 a // why do we want to do this? (routine below does it too)
- 01BC53: D0 03 bne $1bc58
- 01BC55: CE FA 00 dec $00fa
- 01BC58: 80 retf
+ this just seems to be some very buggy checksum code where the games don't even care about the result...
+ (actually it looks like some games might be using it as a PRNG seed?)
+
+ a is 80 when entering here?
+
+ 01BC37: A0 3F ldy #$3f
+ 01BC39: B2 clr a // clear acculuator
+ 01BC3A: 1B spa0 a // store 'accumulator' into byte 0 of PA 'address' register
+ 01BC3B: 9B spa2 a // store 'accumulator' into byte 2 of PA 'address' register
+
+ -- loop point 2
+ 01BC3C: 98 tya // y -> a (3f on first run of loop)
+ 01BC3D: 5B spa1 a // store 'accumulator' into byte 1 of PA 'address' register (003f00 on first loop?)
+
+ -- loop point 1
+ 01BC3E: A3 ldal0 a // read byte 0 of 32-bit 'long' register into accumulator
+ 01BC3F: 73 adcpa // adc ($Address PA), y
+ 01BC40: 83 stal0 a // store accumulator back in byte 0 of 32-bit 'long' register (even byte checksum?)
+ 01BC41: FB incpa // increase 'address' register PA
+ 01BC42: A7 ldal1 a // read byte 1 of 32-bit 'long' register into accumulator
+ 01BC43: 73 adcpa // adc ($Address PA), y
+ 01BC44: 87 stal1 a // store accumulator back in byte 0 of 32-bit 'long' register (odd byte checksum?)
+ 01BC45: FB incpa // increase 'address' register PA
+ 01BC46: D0 F6 bne $1bc3e // (branch based on PA increase, so PA must set flags?, probably overflows after 0xffff if upper byte is 'bank'? or at 0xff if this really is a mirror of the function below
+
+ 01BC48: 88 dey // decrease y, which contained 3f at the start
+ 01BC49: 10 F1 bpl $1bc3c // branch back to loop point 2 to reload counter
+
+ // contains the odd byte checksum once we drop out the loop
+ 01BC4B: 8D FB 00 sta $00fb // store it in zero page memory
+ 01BC4E: A3 ldal0 a // get the even byte checksum from byte 0 of 32-bit 'long' register
+ 01BC4F: 8D FA 00 sta $00fa // store it in zero page memory
+ 01BC52: 07 oral1 a // why do we want to do this? (routine below does it too)
+ 01BC53: D0 03 bne $1bc58
+ 01BC55: CE FA 00 dec $00fa
+ 01BC58: 80 retf
this is presumably meant to be similar to the function found in Namco
Nostalgia 2
- // A is 80 on entry
+ // A is 80 on entry
09FFD8: A9 3F lda #$3f
09FFDA: 85 01 sta $01 // set upper bit of pointer at 0x0000 to 3f (it completely fails to initialize the ram at 00, we currently init it to ff, but should probably be 0?)
09FFDC: A0 00 ldy #$00 // clear inner loop counter
- -- loop point 1 and 2
+ -- loop point 1 and 2
09FFDE: AD FA 00 lda $00fa // read current even byte checksum value from zero page ram fa (game also completely fails to initialize this)
09FFE1: 71 00 adc ($00), y // so 3f00 + y first outer loop, 3e00 + y second outer loop with y increasing in inner loop (add byte read to even checksum byte?)
09FFE3: 8D FA 00 sta $00fa // store even checksum at 0xfa in zero page ram
@@ -82,8 +82,8 @@
09FFF2: C6 01 dec $01 // decrease accumulator (started at 3f) (inner loop counter already 0 because it overflowed)
09FFF4: 10 E8 bpl $9ffde // branch back
- // checksums are already in place after loop so no need to copy them like in above
- 09FFF6: 0D FA 00 ora $00fa // same weird 'or' call
+ // checksums are already in place after loop so no need to copy them like in above
+ 09FFF6: 0D FA 00 ora $00fa // same weird 'or' call
--
09FFF9: D0 03 bne $9fffe
09FFFB: CE FA 00 dec $00fa
diff --git a/src/devices/cpu/m6502/xavix2000.h b/src/devices/cpu/m6502/xavix2000.h
index 979299d2d67..9ea151210ac 100644
--- a/src/devices/cpu/m6502/xavix2000.h
+++ b/src/devices/cpu/m6502/xavix2000.h
@@ -61,7 +61,7 @@ public:
O(adcl1_acc);
O(adcl2_acc);
O(adcl3_acc);
-
+
O(stal0_acc);
O(stal1_acc);
O(stal2_acc);
diff --git a/src/devices/cpu/m68000/m68kdasm.cpp b/src/devices/cpu/m68000/m68kdasm.cpp
index 78d240ad737..a61acff8631 100644
--- a/src/devices/cpu/m68000/m68kdasm.cpp
+++ b/src/devices/cpu/m68000/m68kdasm.cpp
@@ -53,7 +53,8 @@ std::string m68k_disassembler::make_signed_hex_str_32(u32 val)
std::string m68k_disassembler::get_imm_str_s(u32 size)
{
- switch(size) {
+ switch(size)
+ {
case 0: return util::string_format("#%s", make_signed_hex_str_8(read_imm_8()));
case 1: return util::string_format("#%s", make_signed_hex_str_16(read_imm_16()));
case 2: return util::string_format("#%s", make_signed_hex_str_32(read_imm_32()));
@@ -63,7 +64,8 @@ std::string m68k_disassembler::get_imm_str_s(u32 size)
std::string m68k_disassembler::get_imm_str_u(u32 size)
{
- switch(size) {
+ switch(size)
+ {
case 0: return util::string_format("#$%x", read_imm_8());
case 1: return util::string_format("#$%x", read_imm_16());
case 2: return util::string_format("#$%x", read_imm_32());
@@ -2996,7 +2998,8 @@ std::string m68k_disassembler::d68851_p000()
if ((modes & 0xe000) == 0x8000) // PTEST
{
- if (modes & 0x100) {
+ if (modes & 0x100)
+ {
return util::string_format("ptest%c %s, %s, %d, @A%d",
(modes & 0x200) ? 'r' : 'w',
fc_to_string(modes),
diff --git a/src/devices/cpu/m68000/m68kmmu.h b/src/devices/cpu/m68000/m68kmmu.h
index 5abd2b8f29e..60fda569f85 100644
--- a/src/devices/cpu/m68000/m68kmmu.h
+++ b/src/devices/cpu/m68000/m68kmmu.h
@@ -125,15 +125,13 @@ void pmmu_set_buserror(uint32_t addr_in)
*/
void pmmu_atc_add(uint32_t logical, uint32_t physical, int fc)
{
- int i, found;
-
// get page size (i.e. # of bits to ignore); is 10 for Apollo
int ps = (m_mmu_tc >> 20) & 0xf;
// Note: exact emulation would use (logical >> ps) << (ps-8)
- uint32_t atc_tag = M68K_MMU_ATC_VALID | ((fc &7) << 24)| logical >> ps;
+ uint32_t atc_tag = M68K_MMU_ATC_VALID | ((fc & 7) << 24)| logical >> ps;
// first see if this is already in the cache
- for (i = 0; i < MMU_ATC_ENTRIES; i++)
+ for (int i = 0; i < MMU_ATC_ENTRIES; i++)
{
// if tag bits and function code match, don't add
if (m_mmu_atc_tag[i] == atc_tag)
@@ -143,8 +141,8 @@ void pmmu_atc_add(uint32_t logical, uint32_t physical, int fc)
}
// find an open entry
- found = -1;
- for (i = 0; i < MMU_ATC_ENTRIES; i++)
+ int found = -1;
+ for (int i = 0; i < MMU_ATC_ENTRIES; i++)
{
if (!(m_mmu_atc_tag[i] & M68K_MMU_ATC_VALID))
{
@@ -165,9 +163,9 @@ void pmmu_atc_add(uint32_t logical, uint32_t physical, int fc)
}
// add the entry
- MMULOG("ATC[%2d] add: log %08x -> phys %08x (fc=%d)\n", found, (logical>>ps) << ps, (physical >> ps) << ps, fc);
+ MMULOG("ATC[%2d] add: log %08x -> phys %08x (fc=%d)\n", found, (logical >> ps) << ps, (physical >> ps) << ps, fc);
m_mmu_atc_tag[found] = atc_tag;
- m_mmu_atc_data[found] = (physical >> ps) << (ps-8);
+ m_mmu_atc_data[found] = (physical >> ps) << (ps - 8);
if (m_mmu_tmp_sr & M68K_MMU_SR_WRITE_PROTECT)
{
@@ -182,10 +180,9 @@ void pmmu_atc_add(uint32_t logical, uint32_t physical, int fc)
*/
void pmmu_atc_flush()
{
- int i;
MMULOG("ATC flush: pc=%08x\n", m_ppc);
- for (i = 0; i < MMU_ATC_ENTRIES; i++)
+ for (int i = 0; i < MMU_ATC_ENTRIES; i++)
{
m_mmu_atc_tag[i] = 0;
}
@@ -242,44 +239,47 @@ inline uint32_t get_dt3_table_entry(uint32_t tptr, uint8_t fc, uint8_t ptest)
return (tbl_entry & ~M68K_MMU_DF_DT) | dt;
}
-bool pmmu_atc_lookup(const uint32_t addr_in, const int fc,
- const int ptest, uint32_t& addr_out)
+bool pmmu_atc_lookup(const uint32_t addr_in, const int fc, const int ptest, uint32_t& addr_out)
{
const int ps = (m_mmu_tc >> 20) & 0xf;
- const uint32_t atc_tag = M68K_MMU_ATC_VALID | ((fc & 7) << 24) | (addr_in >> ps);
-
- for (int i = 0; i < MMU_ATC_ENTRIES; i++) {
- if (m_mmu_atc_tag[i] != atc_tag)
- continue;
-
- if (!m_mmu_tmp_rw && (m_mmu_atc_data[i] & M68K_MMU_ATC_WRITE_PR))
- continue;
- if (!m_mmu_tmp_rw && !(m_mmu_atc_data[i] & M68K_MMU_ATC_MODIFIED))
- continue;
-
- // read access or write access and not write protected
- if (!ptest) {
- // FIXME: must set modified in PMMU tables as well
- m_mmu_atc_data[i] |= (!m_mmu_tmp_rw ? M68K_MMU_ATC_MODIFIED : 0);
- } else {
- uint16_t sr = 0;
-
- if (m_mmu_atc_data[i] & M68K_MMU_ATC_MODIFIED)
- sr = M68K_MMU_SR_MODIFIED;
-
- if (m_mmu_atc_data[i] & M68K_MMU_ATC_WRITE_PR)
- sr |= M68K_MMU_SR_WRITE_PROTECT;
-
- if (m_mmu_atc_data[i] & M68K_MMU_ATC_BUSERROR)
- sr |= M68K_MMU_SR_BUS_ERROR|M68K_MMU_SR_INVALID;
- m_mmu_tmp_sr = sr;
- }
- addr_out = (m_mmu_atc_data[i] << 8) | (addr_in & ~(~0 << ps));
- return true;
- }
- if (ptest)
- m_mmu_tmp_sr = M68K_MMU_SR_INVALID;
- return false;
+ const uint32_t atc_tag = M68K_MMU_ATC_VALID | ((fc & 7) << 24) | (addr_in >> ps);
+
+ for (int i = 0; i < MMU_ATC_ENTRIES; i++)
+ {
+ if (m_mmu_atc_tag[i] != atc_tag)
+ continue;
+
+ if (!m_mmu_tmp_rw && (m_mmu_atc_data[i] & M68K_MMU_ATC_WRITE_PR))
+ continue;
+ if (!m_mmu_tmp_rw && !(m_mmu_atc_data[i] & M68K_MMU_ATC_MODIFIED))
+ continue;
+
+ // read access or write access and not write protected
+ if (!ptest)
+ {
+ // FIXME: must set modified in PMMU tables as well
+ m_mmu_atc_data[i] |= (!m_mmu_tmp_rw ? M68K_MMU_ATC_MODIFIED : 0);
+ }
+ else
+ {
+ uint16_t sr = 0;
+
+ if (m_mmu_atc_data[i] & M68K_MMU_ATC_MODIFIED)
+ sr = M68K_MMU_SR_MODIFIED;
+
+ if (m_mmu_atc_data[i] & M68K_MMU_ATC_WRITE_PR)
+ sr |= M68K_MMU_SR_WRITE_PROTECT;
+
+ if (m_mmu_atc_data[i] & M68K_MMU_ATC_BUSERROR)
+ sr |= M68K_MMU_SR_BUS_ERROR|M68K_MMU_SR_INVALID;
+ m_mmu_tmp_sr = sr;
+ }
+ addr_out = (m_mmu_atc_data[i] << 8) | (addr_in & ~(~0 << ps));
+ return true;
+ }
+ if (ptest)
+ m_mmu_tmp_sr = M68K_MMU_SR_INVALID;
+ return false;
}
bool pmmu_match_tt(uint32_t addr_in, int fc, uint32_t tt)
@@ -441,14 +441,14 @@ uint32_t pmmu_translate_addr_with_fc_040(uint32_t addr_in, uint8_t fc, uint8_t p
}
else
{
- fatalerror("68040: function code %d is neither data nor program!\n", fc&7);
+ fatalerror("68040: function code %d is neither data nor program!\n", fc & 7);
}
if (tt0 & 0x8000)
{
- static int fcmask[4] = { 4, 4, 0, 0 };
- static int fcmatch[4] = { 0, 4, 0, 0 };
- uint32_t mask = (tt0>>16) & 0xff;
+ static constexpr int fcmask[4] = { 4, 4, 0, 0 };
+ static constexpr int fcmatch[4] = { 0, 4, 0, 0 };
+ uint32_t mask = (tt0 >> 16) & 0xff;
mask ^= 0xff;
mask <<= 24;
@@ -468,7 +468,7 @@ uint32_t pmmu_translate_addr_with_fc_040(uint32_t addr_in, uint8_t fc, uint8_t p
{
static int fcmask[4] = { 4, 4, 0, 0 };
static int fcmatch[4] = { 0, 4, 0, 0 };
- uint32_t mask = (tt1>>16) & 0xff;
+ uint32_t mask = (tt1 >> 16) & 0xff;
mask ^= 0xff;
mask <<= 24;
@@ -486,8 +486,8 @@ uint32_t pmmu_translate_addr_with_fc_040(uint32_t addr_in, uint8_t fc, uint8_t p
if (m_pmmu_enabled)
{
- uint32_t root_idx = (addr_in>>25) & 0x7f;
- uint32_t ptr_idx = (addr_in>>18) & 0x7f;
+ uint32_t root_idx = (addr_in >> 25) & 0x7f;
+ uint32_t ptr_idx = (addr_in >> 18) & 0x7f;
uint32_t page_idx, page;
uint32_t root_ptr, pointer_ptr, page_ptr;
uint32_t root_entry, pointer_entry, page_entry;
@@ -599,7 +599,7 @@ uint32_t pmmu_translate_addr_with_fc_040(uint32_t addr_in, uint8_t fc, uint8_t p
m_mmu_last_page_entry = page_entry;
// is the page write protected or supervisor protected?
- if ((((page_entry & 4) && !m_mmu_tmp_rw) || ((page_entry & 0x80) && !(fc&4))) && !ptest)
+ if ((((page_entry & 4) && !m_mmu_tmp_rw) || ((page_entry & 0x80) && !(fc & 4))) && !ptest)
{
pmmu_set_buserror(addr_in);
return addr_in;
@@ -678,7 +678,8 @@ uint32_t pmmu_translate_addr(uint32_t addr_in)
addr_out = pmmu_translate_addr_with_fc(addr_in, m_mmu_tmp_fc, 0);
}
-// if (m_mmu_tmp_buserror_occurred > 0) {
+// if (m_mmu_tmp_buserror_occurred > 0)
+// {
// MMULOG("PMMU: pc=%08x sp=%08x va=%08x pa=%08x - invalid Table mode for level=%d (buserror %d)\n",
// m_ppc, REG_A()[7], addr_in, addr_out, m_mmu_tmp_sr & M68K_MMU_SR_LEVEL_3,
// m_mmu_tmp_buserror_occurred);
@@ -908,7 +909,7 @@ void m68851_pmove_put(uint32_t ea, uint16_t modes)
void m68851_pmove(uint32_t ea, uint16_t modes)
{
- switch ((modes>>13) & 0x7)
+ switch ((modes >> 13) & 0x7)
{
case 0: // MC68030/040 form with FD bit
case 2: // MC68851 form, FD never set
@@ -934,7 +935,7 @@ void m68851_pmove(uint32_t ea, uint16_t modes)
break;
default:
- logerror("680x0: unknown PMOVE mode %x (modes %04x) (PC %x)\n", (modes>>13) & 0x7, modes, m_pc);
+ logerror("680x0: unknown PMOVE mode %x (modes %04x) (PC %x)\n", (modes >> 13) & 0x7, modes, m_pc);
break;
}
@@ -964,7 +965,7 @@ void m68851_mmu_ops()
}
else // the rest are 1111000xxxXXXXXX where xxx is the instruction family
{
- switch ((m_ir>>9) & 0x7)
+ switch ((m_ir >> 9) & 0x7)
{
case 0:
modes = OPER_I_16();
@@ -1006,7 +1007,7 @@ void m68851_mmu_ops()
break;
default:
- logerror("680x0: unknown PMMU instruction group %d\n", (m_ir>>9) & 0x7);
+ logerror("680x0: unknown PMMU instruction group %d\n", (m_ir >> 9) & 0x7);
break;
}
}
diff --git a/src/devices/cpu/sparc/mb86901.cpp b/src/devices/cpu/sparc/mb86901.cpp
index 2d40cb7ce97..809df3db8f3 100644
--- a/src/devices/cpu/sparc/mb86901.cpp
+++ b/src/devices/cpu/sparc/mb86901.cpp
@@ -954,10 +954,10 @@ next;
if (rd != 0) then r[rd] <- result;
if (ANDcccc or ANDNcc or ORcc or ORNcc or XORcc or XNORcc) then (
- N <- result<31>;
- Z <- if (result = 0) then 1 else 0;
- V <- 0
- C <- 0
+ N <- result<31>;
+ Z <- if (result = 0) then 1 else 0;
+ V <- 0
+ C <- 0
);
*/
@@ -2178,100 +2178,100 @@ void mb86901_device::execute_store(uint32_t op)
/* The SPARC Instruction Manual: Version 8, page 163, "Appendix C - ISP Descriptions - C.9. Instruction Defintions - Load Instructions" (SPARCv8.pdf, pg. 160)
if (LDD or LD or LDSH or LDUH or LDSB or LDUB or LDDF or LDF or LDFSR or LDDC or LDC or LDCSR) then (
- address <- r[rs1] + (if (i = 0) then r[rs2] else sign_extend(simm13));
- addr_space <- (if (S = 0) then 10 else 11)
+ address <- r[rs1] + (if (i = 0) then r[rs2] else sign_extend(simm13));
+ addr_space <- (if (S = 0) then 10 else 11)
) else if (LDDA or LDA or LDSHA or LDUHA or LDSBA or LDUBA) then (
- if (S = 0) then (
- trap <- 1;
- privileged_instruction <- 1
- ) else if (i = 1) then (
- trap <- 1;
- illegal_instruction <- 1
- ) else (
- address <- r[rs1] + r[rs2];
- addr_space <- asi
- )
+ if (S = 0) then (
+ trap <- 1;
+ privileged_instruction <- 1
+ ) else if (i = 1) then (
+ trap <- 1;
+ illegal_instruction <- 1
+ ) else (
+ address <- r[rs1] + r[rs2];
+ addr_space <- asi
+ )
)
next;
if (trap = 0) then (
- if ( (LDF or LDDF or LDFSR) and ((EF = 0) or (bp_FPU_present = 0)) then (
- trap <- 1;
- fp_disabled <- 1
- ) else if ( (LDC or LDDC or LDCSR) and ((EC = 0) or (bp_CP_present = 0)) then (
- trap <- 1;
- cp_disabled <- 1
- ) else if ( ( (LDD or LDDA or LDDF or LDDC) and (address<2:0> != 0)) or
- ((LD or LDA or LDF or LDFSR or LDC or LDCSR) and (address<1:0> != 0)) or
- ((LDSH or LDSHA or LDUH or LDUHA) and address<0> != 0) ) then (
- trap <- 1;
- mem_address_not_aligned <- 1
- ) else if (LDDF and (rd<0> != 0)) then (
- trap <- 1;
- fp_exception <- 1;
- ftt <- invalid_fpr_register
- ) else if ((LDF or LDDF or LDFSR) and (an FPU sequence error is detected)) then (
- trap <- 1;
- fp_exception <- 1;
- ftt <- sequence_error
- ) else if ((LDC or LDDC or LDCSR) and (a CP sequence error is detected)) then (
- trap <- 1;
- cp_exception <- 1;
- { possibly additional implementation-dependent actions }
- )
+ if ( (LDF or LDDF or LDFSR) and ((EF = 0) or (bp_FPU_present = 0)) then (
+ trap <- 1;
+ fp_disabled <- 1
+ ) else if ( (LDC or LDDC or LDCSR) and ((EC = 0) or (bp_CP_present = 0)) then (
+ trap <- 1;
+ cp_disabled <- 1
+ ) else if ( ( (LDD or LDDA or LDDF or LDDC) and (address<2:0> != 0)) or
+ ((LD or LDA or LDF or LDFSR or LDC or LDCSR) and (address<1:0> != 0)) or
+ ((LDSH or LDSHA or LDUH or LDUHA) and address<0> != 0) ) then (
+ trap <- 1;
+ mem_address_not_aligned <- 1
+ ) else if (LDDF and (rd<0> != 0)) then (
+ trap <- 1;
+ fp_exception <- 1;
+ ftt <- invalid_fpr_register
+ ) else if ((LDF or LDDF or LDFSR) and (an FPU sequence error is detected)) then (
+ trap <- 1;
+ fp_exception <- 1;
+ ftt <- sequence_error
+ ) else if ((LDC or LDDC or LDCSR) and (a CP sequence error is detected)) then (
+ trap <- 1;
+ cp_exception <- 1;
+ { possibly additional implementation-dependent actions }
+ )
);
next;
if (trap = 0) then {
- (data, MAE) <- memory_read(addr_space, address);
- next;
- if (MAE = 1) then (
- trap <- 1;
- data_access_exception <- 1;
- ) else (
- if (LDSB or LDSBA or LDUB or LDUBA) then (
- if (address<1:0> = 0) then byte <- data<31:24>
- else if (address<1:0> = 1) then byte <- data<23:16>
- else if (address<1:0> = 2) then byte <- data<15: 8>
- else if (address<1:0> = 3) then byte <- data< 7: 0>
- next;
- if (LDSB or LDSBA) then
- word0 <- sign_extend_byte(byte)
- else
- word0 <- zero_extend_byte(byte)
- ) else if (LDSH or LDSHA or LDUH or LDUHA) then (
- if (address<1:0> = 0) then halfword <- data<31:16>
- else if (address<1:0> = 2) then halfword <- data<15: 0>
- next;
- if (LDSH or LDSHA) then
- word0 <- sign_extend_halfword(halfword)
- else
- word0 <- zero_extend_halfword(halfword)
- ) else
- word0 <- data
- )
+ (data, MAE) <- memory_read(addr_space, address);
+ next;
+ if (MAE = 1) then (
+ trap <- 1;
+ data_access_exception <- 1;
+ ) else (
+ if (LDSB or LDSBA or LDUB or LDUBA) then (
+ if (address<1:0> = 0) then byte <- data<31:24>
+ else if (address<1:0> = 1) then byte <- data<23:16>
+ else if (address<1:0> = 2) then byte <- data<15: 8>
+ else if (address<1:0> = 3) then byte <- data< 7: 0>
+ next;
+ if (LDSB or LDSBA) then
+ word0 <- sign_extend_byte(byte)
+ else
+ word0 <- zero_extend_byte(byte)
+ ) else if (LDSH or LDSHA or LDUH or LDUHA) then (
+ if (address<1:0> = 0) then halfword <- data<31:16>
+ else if (address<1:0> = 2) then halfword <- data<15: 0>
+ next;
+ if (LDSH or LDSHA) then
+ word0 <- sign_extend_halfword(halfword)
+ else
+ word0 <- zero_extend_halfword(halfword)
+ ) else
+ word0 <- data
+ )
);
next;
if (trap = 0) then (
- if ( (rd != 0) and (LD or LDA or LDSH or LDSHA
- or LDUHA or LDUH or LDSB or LDSBA or LDUB or LDUBA) ) then
- r[rd] <- word0
- else if (LDF) then f[rd] <- word0
- else if (LDC) then { implementation-dependent actions }
- else if (LDFSR) then FSR <- word0
- else if (LDCSR) then CSR <- word0
- else if (LDD or LDDA) then r[rd and 11110] <- word0
- else if (LDDF) then f[rd and 11110] <- word0
- else if (LDDC) then { implementation-dependent actions }
+ if ( (rd != 0) and (LD or LDA or LDSH or LDSHA
+ or LDUHA or LDUH or LDSB or LDSBA or LDUB or LDUBA) ) then
+ r[rd] <- word0
+ else if (LDF) then f[rd] <- word0
+ else if (LDC) then { implementation-dependent actions }
+ else if (LDFSR) then FSR <- word0
+ else if (LDCSR) then CSR <- word0
+ else if (LDD or LDDA) then r[rd and 11110] <- word0
+ else if (LDDF) then f[rd and 11110] <- word0
+ else if (LDDC) then { implementation-dependent actions }
);
next;
if (((trap = 0) and (LDD or LDDA or LDDF or LDDC)) then (
- (word1, MAE) <- memory_read(addr_space, address + 4);
- next;
- if (MAE = 1) then ( { MAE = 1 only due to a "non-resumable machine-check error" }
- trap <- 1;
- data_access_exception <- 1 )
- else if (LDD or LDDA) then r[rd or 1] <- word1
- else if (LDDF) then f[rd or 1] <- word1
- else if (LDDC) then { implementation-dependent actions }
+ (word1, MAE) <- memory_read(addr_space, address + 4);
+ next;
+ if (MAE = 1) then ( { MAE = 1 only due to a "non-resumable machine-check error" }
+ trap <- 1;
+ data_access_exception <- 1 )
+ else if (LDD or LDDA) then r[rd or 1] <- word1
+ else if (LDDF) then f[rd or 1] <- word1
+ else if (LDDC) then { implementation-dependent actions }
);
*/
@@ -3389,16 +3389,16 @@ inline void mb86901_device::execute_group3(uint32_t op)
bool mb86901_device::evaluate_condition(uint32_t op)
{
- // COND & 8
- // 0 8
- // bn ba
- // bz bne
- // ble bg
- // bl bge
- // bleu bgu
- // bcs bcc
- // bneg bpos
- // bvs bvc
+ // COND & 8
+ // 0 8
+ // bn ba
+ // bz bne
+ // ble bg
+ // bl bge
+ // bleu bgu
+ // bcs bcc
+ // bneg bpos
+ // bvs bvc
switch(COND)
{
diff --git a/src/devices/cpu/sparc/sparcdefs.h b/src/devices/cpu/sparc/sparcdefs.h
index 38227f4c668..f023da44679 100644
--- a/src/devices/cpu/sparc/sparcdefs.h
+++ b/src/devices/cpu/sparc/sparcdefs.h
@@ -127,7 +127,7 @@
#define CMASK ((op >> 4) & 7)
#define RD ((op >> 25) & 31)
-#define RDBITS (op & 0x3e000000)
+#define RDBITS (op & 0x3e000000)
#define RS1 ((op >> 14) & 31)
#define RS2 (op & 31)
diff --git a/src/devices/cpu/unsp/unsp.cpp b/src/devices/cpu/unsp/unsp.cpp
index 8b8ce63ba42..4f9c5e64745 100644
--- a/src/devices/cpu/unsp/unsp.cpp
+++ b/src/devices/cpu/unsp/unsp.cpp
@@ -2,13 +2,13 @@
// copyright-holders:Segher Boessenkool,Ryan Holtz
/*****************************************************************************
- SunPlus micro'nSP emulator
+ SunPlus micro'nSP emulator
- Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
- Licensed under the terms of the GNU GPL, version 2
- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
+ Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
+ Licensed under the terms of the GNU GPL, version 2
+ http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
- Ported to MAME framework by Ryan Holtz
+ Ported to MAME framework by Ryan Holtz
*****************************************************************************/
diff --git a/src/devices/cpu/unsp/unsp.h b/src/devices/cpu/unsp/unsp.h
index d685afccfe0..1e42e2d0f89 100644
--- a/src/devices/cpu/unsp/unsp.h
+++ b/src/devices/cpu/unsp/unsp.h
@@ -2,13 +2,13 @@
// copyright-holders:Segher Boessenkool,Ryan Holtz
/*****************************************************************************
- SunPlus micro'nSP emulator
+ SunPlus micro'nSP emulator
- Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
- Licensed under the terms of the GNU GPL, version 2
- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
+ Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
+ Licensed under the terms of the GNU GPL, version 2
+ http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
- Ported to MAME framework by Ryan Holtz
+ Ported to MAME framework by Ryan Holtz
*****************************************************************************/
@@ -17,7 +17,7 @@
#pragma once
-#define UNSP_LOG_OPCODES (0)
+#define UNSP_LOG_OPCODES (0)
enum
{
diff --git a/src/devices/cpu/unsp/unspdasm.cpp b/src/devices/cpu/unsp/unspdasm.cpp
index ad67ce9d17e..8ac5c088b67 100644
--- a/src/devices/cpu/unsp/unspdasm.cpp
+++ b/src/devices/cpu/unsp/unspdasm.cpp
@@ -2,11 +2,11 @@
// copyright-holders:Segher Boessenkool
/*****************************************************************************
- SunPlus micro'nSP disassembler
+ SunPlus micro'nSP disassembler
- Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
- Licensed under the terms of the GNU GPL, version 2
- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
+ Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
+ Licensed under the terms of the GNU GPL, version 2
+ http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
*****************************************************************************/
@@ -166,7 +166,7 @@ offs_t unsp_disassembler::disassemble(std::ostream &stream, offs_t pc, uint16_t
util::stream_format(stream, "reti");
else if (opA+1 < 8 && opA+opN < 8)
util::stream_format(stream, "pop %s, %s from [%s]",
- regs[opA+1], regs[opA+opN], regs[opB]);
+ regs[opA+1], regs[opA+opN], regs[opB]);
else
util::stream_format(stream, "<BAD>");
return UNSP_DASM_OK;
@@ -176,7 +176,7 @@ offs_t unsp_disassembler::disassemble(std::ostream &stream, offs_t pc, uint16_t
case 0x2d:
if (opA+1 >= opN && opA < opN+7)
util::stream_format(stream, "push %s, %s to [%s]",
- regs[opA+1-opN], regs[opA], regs[opB]);
+ regs[opA+1-opN], regs[opA], regs[opB]);
else
util::stream_format(stream, "<BAD>");
return UNSP_DASM_OK;
diff --git a/src/devices/cpu/unsp/unspdasm.h b/src/devices/cpu/unsp/unspdasm.h
index eb921b22346..c60ca14f382 100644
--- a/src/devices/cpu/unsp/unspdasm.h
+++ b/src/devices/cpu/unsp/unspdasm.h
@@ -2,11 +2,11 @@
// copyright-holders:Segher Boessenkool
/*****************************************************************************
- SunPlus micro'nSP disassembler
+ SunPlus micro'nSP disassembler
- Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
- Licensed under the terms of the GNU GPL, version 2
- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
+ Copyright 2008-2017 Segher Boessenkool <segher@kernel.crashing.org>
+ Licensed under the terms of the GNU GPL, version 2
+ http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
*****************************************************************************/
diff --git a/src/devices/machine/am9517a.cpp b/src/devices/machine/am9517a.cpp
index 55a5cab0d8c..cd6955b63ed 100644
--- a/src/devices/machine/am9517a.cpp
+++ b/src/devices/machine/am9517a.cpp
@@ -817,22 +817,9 @@ WRITE8_MEMBER( am9517a_device::write )
switch (offset & 0x0f)
{
case REGISTER_COMMAND:
- {
- bool old_dack_active_high = COMMAND_DACK_ACTIVE_HIGH;
- bool old_dreq_active_low = COMMAND_DREQ_ACTIVE_LOW;
- m_command = data;
- LOG("AM9517A Command Register: %02x\n", m_command);
+ m_command = data;
- if (old_dack_active_high != COMMAND_DACK_ACTIVE_HIGH)
- {
- set_dack(); // Line values for DACK changed, update them to reflect the new state.
- }
- if (old_dreq_active_low != COMMAND_DREQ_ACTIVE_LOW)
- {
- // Invert the request bits because the interpretation of line levels has changed
- m_status ^= 0xF0;
- }
- }
+ LOG("AM9517A Command Register: %02x\n", m_command);
break;
case REGISTER_REQUEST:
@@ -894,12 +881,8 @@ WRITE8_MEMBER( am9517a_device::write )
case REGISTER_MASTER_CLEAR:
LOG("AM9517A Master Clear\n");
- {
- // Even the master reset should not clear the state of the input lines.
- int stored_status = m_status;
- device_reset();
- m_status = stored_status & 0xF0;
- }
+
+ device_reset();
break;
case REGISTER_CLEAR_MASK:
diff --git a/src/devices/machine/mb87030.cpp b/src/devices/machine/mb87030.cpp
index 41b08682e81..966cb1e6699 100644
--- a/src/devices/machine/mb87030.cpp
+++ b/src/devices/machine/mb87030.cpp
@@ -457,11 +457,11 @@ void mb87030_device::device_start()
save_item(NAME(m_hdb));
save_item(NAME(m_hdb_loaded));
save_item(NAME(m_send_atn_during_selection));
-// save_item(NAME(m_fifo));
+// save_item(NAME(m_fifo));
save_item(NAME(m_scsi_phase));
save_item(NAME(m_scsi_ctrl));
save_item(NAME(m_dma_transfer));
-// save_item(NAME(m_state));
+// save_item(NAME(m_state));
}
void mb87030_device::scsi_ctrl_changed()
@@ -551,9 +551,9 @@ WRITE8_MEMBER(mb87030_device::scmd_w)
break;
case SCMD_CMD_RESET_ATN:
LOG("%s: Reset ATN\n", __FUNCTION__);
-// if (m_state == State::Idle)
+// if (m_state == State::Idle)
m_send_atn_during_selection = false;
-// else
+// else
scsi_set_ctrl(0, S_ATN);
break;
case SCMD_CMD_SET_ATN:
diff --git a/src/devices/machine/msm58321.cpp b/src/devices/machine/msm58321.cpp
index 550645b5255..2dc268d8bc1 100644
--- a/src/devices/machine/msm58321.cpp
+++ b/src/devices/machine/msm58321.cpp
@@ -129,7 +129,8 @@ inline void msm58321_device::write_counter(int address, int data)
{
int flag = 0;
- switch (address) {
+ switch (address)
+ {
case REGISTER_H1:
flag = m_reg[REGISTER_H10] & H10_24;
if (!flag)
@@ -160,8 +161,8 @@ inline void msm58321_device::write_counter(int address, int data)
// msm58321_device - constructor
//-------------------------------------------------
-msm58321_device::msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
- : device_t(mconfig, MSM58321, tag, owner, clock),
+msm58321_device::msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
+ device_t(mconfig, MSM58321, tag, owner, clock),
device_rtc_interface(mconfig, *this),
device_nvram_interface(mconfig, *this),
m_year0(0),
@@ -254,7 +255,9 @@ void msm58321_device::device_timer(emu_timer &timer, device_timer_id id, int par
{
m_reg[REGISTER_REF0] |= 1;
m_reg[REGISTER_REF1] |= 1;
- } else {
+ }
+ else
+ {
m_reg[REGISTER_REF0] &= ~1;
m_reg[REGISTER_REF1] &= ~1;
}
diff --git a/src/devices/machine/scc2698b.cpp b/src/devices/machine/scc2698b.cpp
index fce6ada6a66..1f6c537f52d 100644
--- a/src/devices/machine/scc2698b.cpp
+++ b/src/devices/machine/scc2698b.cpp
@@ -2,23 +2,23 @@
// copyright-holders:Brandon Munger, Stephen Stair
/*********************************************************************
- scc2698b.cpp
+ scc2698b.cpp
- Enhanced Octal Universal Asynchronous Receiver/Transmitter
+ Enhanced Octal Universal Asynchronous Receiver/Transmitter
Notes:
- This device is similiar to four 2681 DUART chips tied together
- in a single package, with some shared resources.
- The 2681 DUART is implemented in scn2681_device - but this
- chip is being independently emulated seperately for mainly
- educational purposes. When functionality for this device is
- completed we will consider merging the devices if it's
- practical.
+ This device is similiar to four 2681 DUART chips tied together
+ in a single package, with some shared resources.
+ The 2681 DUART is implemented in scn2681_device - but this
+ chip is being independently emulated seperately for mainly
+ educational purposes. When functionality for this device is
+ completed we will consider merging the devices if it's
+ practical.
Quirks:
- * Reading the RX Holding register will advance the HW FIFO even if
- there is no data to be read. This is not currently emulated but
- might be interesting to characterize in HW and emulate properly.
+ * Reading the RX Holding register will advance the HW FIFO even if
+ there is no data to be read. This is not currently emulated but
+ might be interesting to characterize in HW and emulate properly.
*********************************************************************/
@@ -26,24 +26,28 @@ Quirks:
#include "emu.h"
#include "scc2698b.h"
-DEFINE_DEVICE_TYPE(SCC2698B, scc2698b_device, "scc2698b", "SCC2698B Octal UART")
-DEFINE_DEVICE_TYPE(SCC2698B_CHANNEL, scc2698b_channel, "scc2698b_channel", "UART channel")
+#define LOG_GENERAL (1U << 0)
+#define LOG_CONFIG_CHANGE (1U << 1)
-#define TRACE_ENABLE 0
-#define TRACE_CONFIG_CHANGE 0
+//#define VERBOSE (LOG_GENERAL | LOG_CONFIG_CHANGE)
+#include "logmacro.h"
+#define TRACE_REGISTER_WRITE(ofs, data, reg_name) LOG("[0x%02X] << 0x%02X (%s)\n", (ofs), (data), (reg_name));
+#define TRACE_REGISTER_READ(ofs, data, reg_name) LOG("[0x%02X] >> 0x%02X (%s)\n", (ofs), (data), (reg_name));
+#define TRACE_CONFIG(...) LOGMASKED(LOG_CONFIG_CHANGE, __VA_ARGS__)
+
+
+DEFINE_DEVICE_TYPE(SCC2698B, scc2698b_device, "scc2698b", "SCC2698B Octal UART")
+DEFINE_DEVICE_TYPE(SCC2698B_CHANNEL, scc2698b_channel, "scc2698b_channel", "UART channel")
-#define TRACE_REGISTER_WRITE(ofs, data, reg_name) if(TRACE_ENABLE) { log_register_access((ofs), (data), "<<", (reg_name)); }
-#define TRACE_REGISTER_READ(ofs, data, reg_name) if(TRACE_ENABLE) { log_register_access((ofs), (data), ">>", (reg_name)); }
-#define TRACE_CONFIG if(TRACE_CONFIG_CHANGE) logerror
// Divider values for baud rate generation
// Expecting a crystal of 3.6864MHz, baud rate is crystal frequency / (divider value * 8)
-static const int BAUD_DIVIDER_ACR7_0[16] =
+static constexpr int BAUD_DIVIDER_ACR7_0[16] =
{
9216,4189,3426,2304,1536,768,384,439,192,96,64,48,12,0,0,0
};
-static const int BAUD_DIVIDER_ACR7_1[16] =
+static constexpr int BAUD_DIVIDER_ACR7_1[16] =
{
6144,4189,12,3072,1536,768,384,230,192,96,256,48,24,0,0,0
};
@@ -86,7 +90,7 @@ void scc2698b_channel::rcv_complete()
// Completed Byte Receive
receive_register_extract();
- if (rx_enable == false)
+ if (!rx_enable)
{
// Skip receive
return;
@@ -126,7 +130,7 @@ void scc2698b_channel::tra_callback()
void scc2698b_channel::write_TXH(int txh)
{
- if (tx_enable == false)
+ if (!tx_enable)
{
logerror("Warning: TX Holding byte ignored because transmitter is disabled.\n");
return;
@@ -206,7 +210,7 @@ void scc2698b_channel::set_tx_enable(bool enable)
}
void scc2698b_channel::set_rx_enable(bool enable)
{
- if (rx_enable == false && enable == true)
+ if (!rx_enable && enable)
{
receive_register_reset();
}
@@ -218,7 +222,7 @@ void scc2698b_channel::set_rx_enable(bool enable)
void scc2698b_channel::update_serial_configuration()
{
// void set_data_frame(int start_bit_count, int data_bit_count, parity_t parity, stop_bits_t stop_bits);
-
+
// Note: unimplemented RTS/CTS control, Error mode bit.
int start_bit_count = 1;
@@ -266,11 +270,10 @@ void scc2698b_channel::update_serial_configuration()
logerror("Warning: Unsupported channel mode selected.\n");
}
- const char* parity_strings[] = { "None", "Odd", "Even", "Mark", "Space" };
- const char* stop_bit_strings[] = { "0","1","1.5","2" };
+ static char const *const parity_strings[] = { "None", "Odd", "Even", "Mark", "Space" };
+ static char const *const stop_bit_strings[] = { "0","1","1.5","2" };
TRACE_CONFIG("Reconfigured channel to %d data bits, %s Parity, %s stop bits\n", data_bit_count, parity_strings[parity_mode], stop_bit_strings[stop_bits]);
-
set_data_frame(start_bit_count, data_bit_count, parity_mode, stop_bits);
}
@@ -324,13 +327,13 @@ void scc2698b_channel::recompute_pin_output(bool force)
if (new_mpp1 != mpp1_value || force)
{
- if (TRACE_ENABLE) logerror("Channel %d MPP1 => %d\n", channel_port, new_mpp1);
+ LOG("Channel %d MPP1 => %d\n", channel_port, new_mpp1);
parent->write_line_mpp1(channel_port, new_mpp1);
mpp1_value = new_mpp1;
}
if (new_mpp2 != mpp2_value || force)
{
- if(TRACE_ENABLE) logerror("Channel %d MPP2 => %d\n", channel_port, new_mpp2);
+ LOG("Channel %d MPP2 => %d\n", channel_port, new_mpp2);
parent->write_line_mpp2(channel_port, new_mpp2);
mpp2_value = new_mpp2;
}
@@ -356,10 +359,10 @@ scc2698b_device::scc2698b_device(const machine_config &mconfig, const char *tag,
write_intr_B(*this),
write_intr_C(*this),
write_intr_D(*this),
- write_a_tx(*this), write_b_tx(*this), write_c_tx(*this), write_d_tx(*this), write_e_tx(*this), write_f_tx(*this), write_g_tx(*this), write_h_tx(*this),
- write_a_mpp1(*this), write_b_mpp1(*this), write_c_mpp1(*this), write_d_mpp1(*this), write_e_mpp1(*this), write_f_mpp1(*this), write_g_mpp1(*this), write_h_mpp1(*this),
- write_a_mpp2(*this), write_b_mpp2(*this), write_c_mpp2(*this), write_d_mpp2(*this), write_e_mpp2(*this), write_f_mpp2(*this), write_g_mpp2(*this), write_h_mpp2(*this),
- write_a_mpo(*this), write_b_mpo(*this), write_c_mpo(*this), write_d_mpo(*this), write_e_mpo(*this), write_f_mpo(*this), write_g_mpo(*this), write_h_mpo(*this)
+ write_tx{ { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this} },
+ write_mpp1{ { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this } },
+ write_mpp2{ { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this } },
+ write_mpo{ { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this }, { *this } }
{
@@ -380,38 +383,14 @@ void scc2698b_device::device_start()
write_intr_C.resolve_safe();
write_intr_D.resolve_safe();
- write_a_tx.resolve_safe();
- write_b_tx.resolve_safe();
- write_c_tx.resolve_safe();
- write_d_tx.resolve_safe();
- write_e_tx.resolve_safe();
- write_f_tx.resolve_safe();
- write_g_tx.resolve_safe();
- write_h_tx.resolve_safe();
- write_a_mpp1.resolve_safe();
- write_b_mpp1.resolve_safe();
- write_c_mpp1.resolve_safe();
- write_d_mpp1.resolve_safe();
- write_e_mpp1.resolve_safe();
- write_f_mpp1.resolve_safe();
- write_g_mpp1.resolve_safe();
- write_h_mpp1.resolve_safe();
- write_a_mpp2.resolve_safe();
- write_b_mpp2.resolve_safe();
- write_c_mpp2.resolve_safe();
- write_d_mpp2.resolve_safe();
- write_e_mpp2.resolve_safe();
- write_f_mpp2.resolve_safe();
- write_g_mpp2.resolve_safe();
- write_h_mpp2.resolve_safe();
- write_a_mpo.resolve_safe();
- write_b_mpo.resolve_safe();
- write_c_mpo.resolve_safe();
- write_d_mpo.resolve_safe();
- write_e_mpo.resolve_safe();
- write_f_mpo.resolve_safe();
- write_g_mpo.resolve_safe();
- write_h_mpo.resolve_safe();
+ for (auto &cb : write_tx)
+ cb.resolve_safe();
+ for (auto &cb : write_mpp1)
+ cb.resolve_safe();
+ for (auto &cb : write_mpp2)
+ cb.resolve_safe();
+ for (auto &cb : write_mpo)
+ cb.resolve_safe();
for (int i = 0; i < 8; i++)
{
@@ -430,64 +409,34 @@ void scc2698b_device::device_reset()
void scc2698b_device::write_line_tx(int port, int value)
{
- switch (port)
- {
- case 0: write_a_tx(value); break;
- case 1: write_b_tx(value); break;
- case 2: write_c_tx(value); break;
- case 3: write_d_tx(value); break;
- case 4: write_e_tx(value); break;
- case 5: write_f_tx(value); break;
- case 6: write_g_tx(value); break;
- case 7: write_h_tx(value); break;
- default: logerror("Unsupported port %d in write_line_tx\n", port);
- }
+ if ((0 <= port) && (ARRAY_LENGTH(write_tx) > port))
+ write_tx[port](value);
+ else
+ logerror("Unsupported port %d in write_line_tx\n", port);
}
+
void scc2698b_device::write_line_mpp1(int port, int value)
{
- switch (port)
- {
- case 0: write_a_mpp1(value); break;
- case 1: write_b_mpp1(value); break;
- case 2: write_c_mpp1(value); break;
- case 3: write_d_mpp1(value); break;
- case 4: write_e_mpp1(value); break;
- case 5: write_f_mpp1(value); break;
- case 6: write_g_mpp1(value); break;
- case 7: write_h_mpp1(value); break;
- default: logerror("Unsupported port %d in write_line_mpp1\n", port);
- }
+ if ((0 <= port) && (ARRAY_LENGTH(write_mpp1) > port))
+ write_mpp1[port](value);
+ else
+ logerror("Unsupported port %d in write_line_mpp1\n", port);
}
void scc2698b_device::write_line_mpp2(int port, int value)
{
- switch (port)
- {
- case 0: write_a_mpp2(value); break;
- case 1: write_b_mpp2(value); break;
- case 2: write_c_mpp2(value); break;
- case 3: write_d_mpp2(value); break;
- case 4: write_e_mpp2(value); break;
- case 5: write_f_mpp2(value); break;
- case 6: write_g_mpp2(value); break;
- case 7: write_h_mpp2(value); break;
- default: logerror("Unsupported port %d in write_line_mpp2\n", port);
- }
+ if ((0 <= port) && (ARRAY_LENGTH(write_mpp2) > port))
+ write_mpp2[port](value);
+ else
+ logerror("Unsupported port %d in write_line_mpp2\n", port);
}
+
void scc2698b_device::write_line_mpo(int port, int value)
{
- switch (port)
- {
- case 0: write_a_mpo(value); break;
- case 1: write_b_mpo(value); break;
- case 2: write_c_mpo(value); break;
- case 3: write_d_mpo(value); break;
- case 4: write_e_mpo(value); break;
- case 5: write_f_mpo(value); break;
- case 6: write_g_mpo(value); break;
- case 7: write_h_mpo(value); break;
- default: logerror("Unsupported port %d in write_line_mpo\n", port);
- }
+ if ((0 <= port) && (ARRAY_LENGTH(write_mpo) > port))
+ write_mpo[port](value);
+ else
+ logerror("Unsupported port %d in write_line_mpo\n", port);
}
@@ -502,13 +451,6 @@ WRITE8_MEMBER(scc2698b_device::write)
}
-void scc2698b_device::log_register_access(int offset, int value, const char* direction, const char* reg_name)
-{
- logerror("[0x%02X] %s 0x%02X (%s)\n", offset, direction, value, reg_name);
-}
-
-
-
uint8_t scc2698b_device::read_reg(int offset)
{
int device = (offset >> 4) & 3;
@@ -694,7 +636,7 @@ void scc2698b_device::write_MR(int port, int value)
void scc2698b_device::write_CSR(int port, int value)
{
scc2698b_channel* channel = get_channel(port);
-
+
channel->CSR = value;
update_port_baudrate(port);
}
diff --git a/src/devices/machine/scc2698b.h b/src/devices/machine/scc2698b.h
index da9ab7ad8b2..fe045aee1b6 100644
--- a/src/devices/machine/scc2698b.h
+++ b/src/devices/machine/scc2698b.h
@@ -1,20 +1,16 @@
// license:GPL-2.0+
// copyright-holders:Brandon Munger, Stephen Stair
-
-
#ifndef MAME_MACHINE_SCC2698B_H
#define MAME_MACHINE_SCC2698B_H
-class scc2698b_device;
-
#include "diserial.h"
-#define SCC2698B_RX_FIFO_SIZE 3
-
// _port should be a letter port index from "a" .. "h"
+class scc2698b_device;
+
class scc2698b_channel : public device_t, public device_serial_interface
{
friend class scc2698b_device;
@@ -49,10 +45,12 @@ public:
int read_SR();
protected:
+ static constexpr unsigned SCC2698B_RX_FIFO_SIZE = 3;
+
virtual void device_start() override;
virtual void device_reset() override;
-// devcb_write_line write_tx, write_mpp1, write_mpp2, write_mpo;
+// devcb_write_line write_tx, write_mpp1, write_mpp2, write_mpo;
int moderegister_ptr;
@@ -88,10 +86,10 @@ public:
void write_reg(int offset, uint8_t data);
uint8_t read_reg(int offset);
- template <class Object> devcb_base &set_intr_A(Object &&cb) { return write_intr_A.set_callback(std::forward<Object>(cb)); }
- template <class Object> devcb_base &set_intr_B(Object &&cb) { return write_intr_B.set_callback(std::forward<Object>(cb)); }
- template <class Object> devcb_base &set_intr_C(Object &&cb) { return write_intr_C.set_callback(std::forward<Object>(cb)); }
- template <class Object> devcb_base &set_intr_D(Object &&cb) { return write_intr_D.set_callback(std::forward<Object>(cb)); }
+ auto intr_A() { return write_intr_A.bind(); }
+ auto intr_B() { return write_intr_B.bind(); }
+ auto intr_C() { return write_intr_C.bind(); }
+ auto intr_D() { return write_intr_D.bind(); }
required_device_array<scc2698b_channel, 8> m_channel;
@@ -110,66 +108,11 @@ public:
void write_line_mpp2(int port, int value);
void write_line_mpo(int port, int value);
-
- auto tx_callback(char port) {
- switch (port) {
- case 'a': return write_a_tx.bind();
- case 'b': return write_b_tx.bind();
- case 'c': return write_c_tx.bind();
- case 'd': return write_d_tx.bind();
- case 'e': return write_e_tx.bind();
- case 'f': return write_f_tx.bind();
- case 'g': return write_g_tx.bind();
- case 'h': return write_h_tx.bind();
- default:
- fatalerror("Wrong port for tx_callback\n");
- }
- }
-
- auto mpp1_callback(char port) {
- switch (port) {
- case 'a': return write_a_mpp1.bind();
- case 'b': return write_b_mpp1.bind();
- case 'c': return write_c_mpp1.bind();
- case 'd': return write_d_mpp1.bind();
- case 'e': return write_e_mpp1.bind();
- case 'f': return write_f_mpp1.bind();
- case 'g': return write_g_mpp1.bind();
- case 'h': return write_h_mpp1.bind();
- default:
- fatalerror("Wrong port for mpp1_callback\n");
- }
- }
-
- auto mpp2_callback(char port) {
- switch (port) {
- case 'a': return write_a_mpp2.bind();
- case 'b': return write_b_mpp2.bind();
- case 'c': return write_c_mpp2.bind();
- case 'd': return write_d_mpp2.bind();
- case 'e': return write_e_mpp2.bind();
- case 'f': return write_f_mpp2.bind();
- case 'g': return write_g_mpp2.bind();
- case 'h': return write_h_mpp2.bind();
- default:
- fatalerror("Wrong port for mpp2_callback\n");
- }
- }
-
- auto mpo_callback(char port) {
- switch (port) {
- case 'a': return write_a_mpo.bind();
- case 'b': return write_b_mpo.bind();
- case 'c': return write_c_mpo.bind();
- case 'd': return write_d_mpo.bind();
- case 'e': return write_e_mpo.bind();
- case 'f': return write_f_mpo.bind();
- case 'g': return write_g_mpo.bind();
- case 'h': return write_h_mpo.bind();
- default:
- fatalerror("Wrong port for mpo_callback\n");
- }
- }
+ // assume contiguous letters - not EBCDIC-friendly
+ template <char Port> auto tx_callback() { return write_tx[Port - 'a'].bind(); }
+ template <char Port> auto mpp1_callback() { return write_mpp1[Port - 'a'].bind(); }
+ template <char Port> auto mpp2_callback() { return write_mpp2[Port - 'a'].bind(); }
+ template <char Port> auto mpo_callback() { return write_mpo[Port - 'a'].bind(); }
protected:
virtual void device_start() override;
@@ -178,12 +121,10 @@ protected:
virtual void device_add_mconfig(machine_config &config) override;
devcb_write_line write_intr_A, write_intr_B, write_intr_C, write_intr_D;
- devcb_write_line write_a_tx, write_b_tx, write_c_tx, write_d_tx, write_e_tx, write_f_tx, write_g_tx, write_h_tx;
- devcb_write_line write_a_mpp1, write_b_mpp1, write_c_mpp1, write_d_mpp1, write_e_mpp1, write_f_mpp1, write_g_mpp1, write_h_mpp1;
- devcb_write_line write_a_mpp2, write_b_mpp2, write_c_mpp2, write_d_mpp2, write_e_mpp2, write_f_mpp2, write_g_mpp2, write_h_mpp2;
- devcb_write_line write_a_mpo, write_b_mpo, write_c_mpo, write_d_mpo, write_e_mpo, write_f_mpo, write_g_mpo, write_h_mpo;
-
- void log_register_access(int offset, int value, const char* direction, const char* reg_name);
+ devcb_write_line write_tx[8];
+ devcb_write_line write_mpp1[8];
+ devcb_write_line write_mpp2[8];
+ devcb_write_line write_mpo[8];
scc2698b_channel* get_channel(int port);
diff --git a/src/devices/machine/smioc.cpp b/src/devices/machine/smioc.cpp
index d3adea99393..3a426e8405b 100644
--- a/src/devices/machine/smioc.cpp
+++ b/src/devices/machine/smioc.cpp
@@ -20,11 +20,11 @@
* CPU - Intel N80C188 L0450591 @ ??MHz - U23
* MCU - Signetics SC87C451CCA68 220CP079109KA 97D8641 - U70
* DMA - KS82C37A - U46, U47, U48, U49, U50
- * SCC - Signetics SCC2698BC1A84 - U67
+ * SCC - Signetics SCC2698BC1A84 - U67
* Memory - NEC D43256AGU-10LL 8948A9038 SRAM 32KB - U51
* Memory - Mitsubishi M5M187AJ 046101-35 SRAM 64K X 1?? - U37
- * Memory - AT&T M79018DX-15B 2K X 9 Dual Port SRAM - U53
- * Memory - AT&T M79018DX-15B 2K X 9 Dual Port SRAM - U54
+ * Memory - AT&T M79018DX-15B 2K X 9 Dual Port SRAM - U53
+ * Memory - AT&T M79018DX-15B 2K X 9 Dual Port SRAM - U54
Logic:
* U8 - 22V10-25JC
@@ -42,21 +42,21 @@
Program Memory:
* 0x00000 - 0x07FFF : SRAM D43256AGU-10LL 32KB
* 0xF8000 - 0xFFFFF : ROM 27C256 PLCC32 32KB
- * 0xC0080 - 0xC008F : KS82C37A - Probably RAM DMA
- * 0xC0090 - 0xC009F : KS82C37A - Serial DMA (Port 1 and 2?)
- * 0xC00A0 - 0xC00AF : KS82C37A - Serial DMA (Port 3 and 4?)
- * 0xC00B0 - 0xC00BF : KS82C37A - Serial DMA (Port 5 and 6?)
- * 0xC00C0 - 0xC00CF : KS82C37A - Serial DMA (Port 7 and 8?)
+ * 0xC0080 - 0xC008F : KS82C37A - Probably RAM DMA
+ * 0xC0090 - 0xC009F : KS82C37A - Serial DMA (Port 1 and 2?)
+ * 0xC00A0 - 0xC00AF : KS82C37A - Serial DMA (Port 3 and 4?)
+ * 0xC00B0 - 0xC00BF : KS82C37A - Serial DMA (Port 5 and 6?)
+ * 0xC00C0 - 0xC00CF : KS82C37A - Serial DMA (Port 7 and 8?)
IO Memory:
* Unknown
TODO:
- * Hook up System Monitor II to RS232 port 2
- * Dump 87C451 rom data and emulate MCU
- * Dump 87C51 on SMIOC interconnect box
- * Dump all PAL chips
- * Hook up status LEDs
+ * Hook up System Monitor II to RS232 port 2
+ * Dump 87C451 rom data and emulate MCU
+ * Dump 87C51 on SMIOC interconnect box
+ * Dump all PAL chips
+ * Hook up status LEDs
*/
#include "emu.h"
@@ -156,12 +156,12 @@ void smioc_device::device_add_mconfig(machine_config &config)
/* SCC2698B */
scc2698b_device &scc2698b(SCC2698B(config, "scc2698b", XTAL(3'686'400)));
- scc2698b.tx_callback('a').set("rs232_p1", FUNC(rs232_port_device::write_txd));
- scc2698b.mpp1_callback('a').set("dma8237_2", FUNC(am9517a_device::dreq1_w)).invert();
- scc2698b.mpp2_callback('a').set("dma8237_2", FUNC(am9517a_device::dreq0_w)).invert();
- scc2698b.tx_callback('b').set("rs232_p2", FUNC(rs232_port_device::write_txd));
- scc2698b.mpp1_callback('b').set("dma8237_2", FUNC(am9517a_device::dreq3_w)).invert();
- scc2698b.mpp2_callback('b').set("dma8237_2", FUNC(am9517a_device::dreq2_w)).invert();
+ scc2698b.tx_callback<'a'>().set("rs232_p1", FUNC(rs232_port_device::write_txd));
+ scc2698b.mpp1_callback<'a'>().set("dma8237_2", FUNC(am9517a_device::dreq1_w)).invert();
+ scc2698b.mpp2_callback<'a'>().set("dma8237_2", FUNC(am9517a_device::dreq0_w)).invert();
+ scc2698b.tx_callback<'b'>().set("rs232_p2", FUNC(rs232_port_device::write_txd));
+ scc2698b.mpp1_callback<'b'>().set("dma8237_2", FUNC(am9517a_device::dreq3_w)).invert();
+ scc2698b.mpp2_callback<'b'>().set("dma8237_2", FUNC(am9517a_device::dreq2_w)).invert();
/* The first dma8237 is set up in cascade mode, and each of its four channels provides HREQ/HACK to the other 4 DMA controllers*/
m_dma8237[0]->out_dack_callback<0>().set("dma8237_2", FUNC(am9517a_device::hack_w));
@@ -171,10 +171,10 @@ void smioc_device::device_add_mconfig(machine_config &config)
m_dma8237[0]->out_hreq_callback().set("dma8237_1", FUNC(am9517a_device::hack_w));
/* Connect base DMA controller's Hold Request to its own Hold ACK
- The CPU doesn't support hold request / hold ack pins, so we will pretend that the DMA controller immediately gets what it wants every time it asks.
- This will keep things moving forward, but the CPU will continue going through DMA requests rather than halting for a few cycles each time.
- It shouldn't cause a problem though.
- */
+ The CPU doesn't support hold request / hold ack pins, so we will pretend that the DMA controller immediately gets what it wants every time it asks.
+ This will keep things moving forward, but the CPU will continue going through DMA requests rather than halting for a few cycles each time.
+ It shouldn't cause a problem though.
+ */
m_dma8237[1]->in_memr_callback().set(FUNC(smioc_device::dma8237_2_dmaread));
m_dma8237[1]->out_memw_callback().set(FUNC(smioc_device::dma8237_2_dmawrite));
@@ -276,7 +276,7 @@ void smioc_device::SendCommand(u16 command)
m_commandValue = command;
m_requestFlags_11D |= 1;
m_deviceBusy = 1;
-
+
// Invalidate status if we hit a command.
m_status = 0;
m_statusvalid = false;
@@ -284,7 +284,7 @@ void smioc_device::SendCommand(u16 command)
m_smioccpu->int2_w(CLEAR_LINE);
m_smioccpu->int2_w(HOLD_LINE);
-
+
}
void smioc_device::SendCommand2(u16 command)
@@ -365,7 +365,7 @@ void smioc_device::SetDmaParameter(smioc_dma_parameter_t param, u16 value)
{
int address = DmaParameterAddress(param);
- const char* paramNames[] = { "smiocdma_sendaddress", "smiocdma_sendlength", "smiocdma_recvaddress", "smiocdma_recvlength" };
+ static char const *const paramNames[] = { "smiocdma_sendaddress", "smiocdma_sendlength", "smiocdma_recvaddress", "smiocdma_recvlength" };
const char* paramName = "?";
if (param >= 0 && param < (sizeof(paramNames) / sizeof(*paramNames)))
{
@@ -441,7 +441,7 @@ void smioc_device::update_and_log(u16& reg, u16 newValue, const char* register_n
READ8_MEMBER(smioc_device::ram2_mmio_r)
{
- const char * description = "";
+ const char *description = "";
u8 data = m_logic_ram[offset & 0xFFF];
switch (offset)
{
@@ -458,7 +458,7 @@ READ8_MEMBER(smioc_device::ram2_mmio_r)
case 0xB86: // Command parameter 2 - C011D Bit 7
description = "(Command Parameter 2)";
break;
- case 0xB87:
+ case 0xB87:
description = "(Command Parameter 2)";
break;
@@ -499,7 +499,7 @@ READ8_MEMBER(smioc_device::ram2_mmio_r)
WRITE8_MEMBER(smioc_device::ram2_mmio_w)
{
- const char * description = "";
+ const char *description = "";
m_logic_ram[offset & 0xFFF] = data;
@@ -590,34 +590,30 @@ READ8_MEMBER(smioc_device::boardlogic_mmio_r)
u8 data = 0xFF;
switch (offset)
{
+ case 0x19: // Hardware revision?
+ // Top bit controls which set of register locations in RAM2 are polled
+ data = 0x7F;
+ break;
- case 0x19: // Hardware revision?
- // Top bit controls which set of register locations in RAM2 are polled
- data = 0x7F;
- break;
-
- case 0x1D: // C011D (HW Request flags)
- data = m_requestFlags_11D;
- LOG_REGISTER_DETAILS("%s C011D Read => %02X\n", machine().time().as_string(), data);
- // Assume this is a clear-on-read register - It is read in one location and all set bits are acted on once it is read.
- m_requestFlags_11D = 0;
-
-
- break;
-
- case 0x1F: // C011F (HW Status flags?)
- // 0x80, 0x40 seem to be HW request to cancel ongoing DMA requests, maybe related to board reset?
- // 0x01 - When this is 0, advance some state perhaps related to talking to the 8051
- data = 0xFF;
- break;
+ case 0x1D: // C011D (HW Request flags)
+ data = m_requestFlags_11D;
+ LOG_REGISTER_DETAILS("%s C011D Read => %02X\n", machine().time().as_string(), data);
+ // Assume this is a clear-on-read register - It is read in one location and all set bits are acted on once it is read.
+ m_requestFlags_11D = 0;
+ break;
- case 0x80: // C0180 - Related to talking to the 87C451 chip interfacing to the breakout box
- data = 0x05; // Hack hack
- // We need the 8051 to provide a pair of bytes with 0x05 followed by a byte with the bottom bit set.
- // For now 0x05 should work to provide this condition, and might make the required status work.
- break;
+ case 0x1F: // C011F (HW Status flags?)
+ // 0x80, 0x40 seem to be HW request to cancel ongoing DMA requests, maybe related to board reset?
+ // 0x01 - When this is 0, advance some state perhaps related to talking to the 8051
+ data = 0xFF;
+ break;
+ case 0x80: // C0180 - Related to talking to the 87C451 chip interfacing to the breakout box
+ data = 0x05; // Hack hack
+ // We need the 8051 to provide a pair of bytes with 0x05 followed by a byte with the bottom bit set.
+ // For now 0x05 should work to provide this condition, and might make the required status work.
+ break;
}
LOG_REGISTER_ACCESS("logic[%04X] => %02X\n", offset, data);
return data;
@@ -627,7 +623,7 @@ WRITE8_MEMBER(smioc_device::boardlogic_mmio_w)
{
switch (offset)
{
- case 0x10: // C0110 (Clear interrupt? This seems to happen a lot but without being related to actually completing anything.)
+ case 0x10: // C0110 (Clear interrupt? This seems to happen a lot but without being related to actually completing anything.)
LOG_REGISTER_DETAILS("%s C0110 Write, DeviceBusy = %02X, RequestFlags = %02X\n", machine().time().as_string(), m_deviceBusy, m_requestFlags_11D);
m_deviceBusy = m_requestFlags_11D;
m_smioccpu->int2_w(CLEAR_LINE);
diff --git a/src/devices/machine/smioc.h b/src/devices/machine/smioc.h
index a756bbcc738..61cfbe88f62 100644
--- a/src/devices/machine/smioc.h
+++ b/src/devices/machine/smioc.h
@@ -124,7 +124,7 @@ private:
required_device<scc2698b_device> m_scc2698b;
required_shared_ptr<uint8_t> m_smioc_ram;
-
+
u8 m_logic_ram[4096]; // 4kb of ram in the 0x4xxxx window, mainly used by the board's logic to proxy command parameters and data.
void smioc_mem(address_map &map);
diff --git a/src/devices/machine/spg2xx.cpp b/src/devices/machine/spg2xx.cpp
index 1293f5593c6..d68dd01b118 100644
--- a/src/devices/machine/spg2xx.cpp
+++ b/src/devices/machine/spg2xx.cpp
@@ -16,42 +16,42 @@
DEFINE_DEVICE_TYPE(SPG24X, spg24x_device, "spg24x", "SPG240-series System-on-a-Chip")
DEFINE_DEVICE_TYPE(SPG28X, spg28x_device, "spg28x", "SPG280-series System-on-a-Chip")
-#define LOG_IO_READS (1U << 0)
-#define LOG_IO_WRITES (1U << 1)
-#define LOG_UNKNOWN_IO (1U << 2)
-#define LOG_IRQS (1U << 3)
-#define LOG_VLINES (1U << 4)
-#define LOG_GPIO (1U << 5)
-#define LOG_UART (1U << 6)
-#define LOG_I2C (1U << 7)
-#define LOG_DMA (1U << 8)
-#define LOG_SEGMENT (1U << 9)
-#define LOG_WATCHDOG (1U << 10)
-#define LOG_TIMERS (1U << 11)
-#define LOG_SPU_READS (1U << 12)
-#define LOG_SPU_WRITES (1U << 13)
-#define LOG_UNKNOWN_SPU (1U << 14)
-#define LOG_CHANNEL_READS (1U << 15)
-#define LOG_CHANNEL_WRITES (1U << 16)
-#define LOG_ENVELOPES (1U << 17)
-#define LOG_SAMPLES (1U << 18)
-#define LOG_RAMPDOWN (1U << 19)
-#define LOG_BEAT (1U << 20)
-#define LOG_PPU_READS (1U << 21)
-#define LOG_PPU_WRITES (1U << 22)
-#define LOG_UNKNOWN_PPU (1U << 23)
-#define LOG_IO (LOG_IO_READS | LOG_IO_WRITES | LOG_IRQS | LOG_GPIO | LOG_UART | LOG_I2C | LOG_DMA | LOG_TIMERS | LOG_UNKNOWN_IO)
-#define LOG_CHANNELS (LOG_CHANNEL_READS | LOG_CHANNEL_WRITES)
-#define LOG_SPU (LOG_SPU_READS | LOG_SPU_WRITES | LOG_UNKNOWN_SPU | LOG_CHANNEL_READS | LOG_CHANNEL_WRITES \
+#define LOG_IO_READS (1U << 0)
+#define LOG_IO_WRITES (1U << 1)
+#define LOG_UNKNOWN_IO (1U << 2)
+#define LOG_IRQS (1U << 3)
+#define LOG_VLINES (1U << 4)
+#define LOG_GPIO (1U << 5)
+#define LOG_UART (1U << 6)
+#define LOG_I2C (1U << 7)
+#define LOG_DMA (1U << 8)
+#define LOG_SEGMENT (1U << 9)
+#define LOG_WATCHDOG (1U << 10)
+#define LOG_TIMERS (1U << 11)
+#define LOG_SPU_READS (1U << 12)
+#define LOG_SPU_WRITES (1U << 13)
+#define LOG_UNKNOWN_SPU (1U << 14)
+#define LOG_CHANNEL_READS (1U << 15)
+#define LOG_CHANNEL_WRITES (1U << 16)
+#define LOG_ENVELOPES (1U << 17)
+#define LOG_SAMPLES (1U << 18)
+#define LOG_RAMPDOWN (1U << 19)
+#define LOG_BEAT (1U << 20)
+#define LOG_PPU_READS (1U << 21)
+#define LOG_PPU_WRITES (1U << 22)
+#define LOG_UNKNOWN_PPU (1U << 23)
+#define LOG_IO (LOG_IO_READS | LOG_IO_WRITES | LOG_IRQS | LOG_GPIO | LOG_UART | LOG_I2C | LOG_DMA | LOG_TIMERS | LOG_UNKNOWN_IO)
+#define LOG_CHANNELS (LOG_CHANNEL_READS | LOG_CHANNEL_WRITES)
+#define LOG_SPU (LOG_SPU_READS | LOG_SPU_WRITES | LOG_UNKNOWN_SPU | LOG_CHANNEL_READS | LOG_CHANNEL_WRITES \
| LOG_ENVELOPES | LOG_SAMPLES | LOG_RAMPDOWN | LOG_BEAT)
-#define LOG_PPU (LOG_PPU_READS | LOG_PPU_WRITES | LOG_UNKNOWN_PPU)
-#define LOG_ALL (LOG_IO | LOG_SPU | LOG_PPU | LOG_VLINES | LOG_SEGMENT)
+#define LOG_PPU (LOG_PPU_READS | LOG_PPU_WRITES | LOG_UNKNOWN_PPU)
+#define LOG_ALL (LOG_IO | LOG_SPU | LOG_PPU | LOG_VLINES | LOG_SEGMENT)
-#define VERBOSE (0)
+#define VERBOSE (0)
#include "logmacro.h"
-#define SPG_DEBUG_VIDEO (0)
-#define SPG_DEBUG_AUDIO (0)
+#define SPG_DEBUG_VIDEO (0)
+#define SPG_DEBUG_AUDIO (0)
#if SPG2XX_VISUAL_AUDIO_DEBUG
static const uint32_t s_visual_debug_palette[8] = {
@@ -70,8 +70,8 @@ static const uint32_t s_visual_debug_palette[8] = {
#define SPG_VDB_VOL 4
#endif
-#define IO_IRQ_ENABLE m_io_regs[0x21]
-#define IO_IRQ_STATUS m_io_regs[0x22]
+#define IO_IRQ_ENABLE m_io_regs[0x21]
+#define IO_IRQ_STATUS m_io_regs[0x22]
#define VIDEO_IRQ_ENABLE m_video_regs[0x62]
#define VIDEO_IRQ_STATUS m_video_regs[0x63]
@@ -2751,4 +2751,4 @@ bool spg2xx_device::audio_envelope_tick(address_space &space, const uint32_t cha
}
LOGMASKED(LOG_ENVELOPES, "envelope %d post-tick, count is now %04x, register is %04x\n", channel, new_count, m_audio_regs[(channel << 4) | AUDIO_ENVELOPE_DATA]);
return edd_changed;
-} \ No newline at end of file
+}
diff --git a/src/devices/machine/spg2xx.h b/src/devices/machine/spg2xx.h
index 812269c7bed..4c21fee1488 100644
--- a/src/devices/machine/spg2xx.h
+++ b/src/devices/machine/spg2xx.h
@@ -68,10 +68,10 @@ protected:
enum
{
PAGE_ENABLE_MASK = 0x0008,
- PAGE_WALLPAPER_MASK = 0x0004,
+ PAGE_WALLPAPER_MASK = 0x0004,
- SPRITE_ENABLE_MASK = 0x0001,
- SPRITE_COORD_TL_MASK = 0x0002,
+ SPRITE_ENABLE_MASK = 0x0001,
+ SPRITE_COORD_TL_MASK = 0x0002,
PAGE_DEPTH_FLAG_MASK = 0x3000,
PAGE_DEPTH_FLAG_SHIFT = 12,
@@ -161,205 +161,205 @@ protected:
enum
{
- AUDIO_WAVE_ADDR = 0x000,
-
- AUDIO_MODE = 0x001,
- AUDIO_WADDR_HIGH_MASK = 0x003f,
- AUDIO_LADDR_HIGH_MASK = 0x0fc0,
- AUDIO_LADDR_HIGH_SHIFT = 6,
- AUDIO_TONE_MODE_MASK = 0x3000,
- AUDIO_TONE_MODE_SHIFT = 12,
- AUDIO_TONE_MODE_SW = 0,
+ AUDIO_WAVE_ADDR = 0x000,
+
+ AUDIO_MODE = 0x001,
+ AUDIO_WADDR_HIGH_MASK = 0x003f,
+ AUDIO_LADDR_HIGH_MASK = 0x0fc0,
+ AUDIO_LADDR_HIGH_SHIFT = 6,
+ AUDIO_TONE_MODE_MASK = 0x3000,
+ AUDIO_TONE_MODE_SHIFT = 12,
+ AUDIO_TONE_MODE_SW = 0,
AUDIO_TONE_MODE_HW_ONESHOT = 1,
- AUDIO_TONE_MODE_HW_LOOP = 2,
- AUDIO_16M_MASK = 0x4000,
- AUDIO_ADPCM_MASK = 0x8000,
-
- AUDIO_LOOP_ADDR = 0x002,
-
- AUDIO_PAN_VOL = 0x003,
- AUDIO_PAN_VOL_MASK = 0x7f7f,
- AUDIO_VOLUME_MASK = 0x007f,
- AUDIO_PAN_MASK = 0x7f00,
- AUDIO_PAN_SHIFT = 8,
-
- AUDIO_ENVELOPE0 = 0x004,
- AUDIO_ENVELOPE_INC_MASK = 0x007f,
- AUDIO_ENVELOPE_SIGN_MASK = 0x0080,
- AUDIO_ENVELOPE_TARGET_MASK = 0x7f00,
- AUDIO_ENVELOPE_TARGET_SHIFT = 8,
+ AUDIO_TONE_MODE_HW_LOOP = 2,
+ AUDIO_16M_MASK = 0x4000,
+ AUDIO_ADPCM_MASK = 0x8000,
+
+ AUDIO_LOOP_ADDR = 0x002,
+
+ AUDIO_PAN_VOL = 0x003,
+ AUDIO_PAN_VOL_MASK = 0x7f7f,
+ AUDIO_VOLUME_MASK = 0x007f,
+ AUDIO_PAN_MASK = 0x7f00,
+ AUDIO_PAN_SHIFT = 8,
+
+ AUDIO_ENVELOPE0 = 0x004,
+ AUDIO_ENVELOPE_INC_MASK = 0x007f,
+ AUDIO_ENVELOPE_SIGN_MASK = 0x0080,
+ AUDIO_ENVELOPE_TARGET_MASK = 0x7f00,
+ AUDIO_ENVELOPE_TARGET_SHIFT = 8,
AUDIO_ENVELOPE_REPEAT_PERIOD_MASK = 0x8000,
- AUDIO_ENVELOPE_DATA = 0x005,
- AUDIO_ENVELOPE_DATA_MASK = 0xff7f,
- AUDIO_EDD_MASK = 0x007f,
- AUDIO_ENVELOPE_COUNT_MASK = 0xff00,
- AUDIO_ENVELOPE_COUNT_SHIFT = 8,
+ AUDIO_ENVELOPE_DATA = 0x005,
+ AUDIO_ENVELOPE_DATA_MASK = 0xff7f,
+ AUDIO_EDD_MASK = 0x007f,
+ AUDIO_ENVELOPE_COUNT_MASK = 0xff00,
+ AUDIO_ENVELOPE_COUNT_SHIFT = 8,
- AUDIO_ENVELOPE1 = 0x006,
- AUDIO_ENVELOPE_LOAD_MASK = 0x00ff,
- AUDIO_ENVELOPE_RPT_MASK = 0x0100,
- AUDIO_ENVELOPE_RPCNT_MASK = 0xfe00,
- AUDIO_ENVELOPE_RPCNT_SHIFT = 9,
+ AUDIO_ENVELOPE1 = 0x006,
+ AUDIO_ENVELOPE_LOAD_MASK = 0x00ff,
+ AUDIO_ENVELOPE_RPT_MASK = 0x0100,
+ AUDIO_ENVELOPE_RPCNT_MASK = 0xfe00,
+ AUDIO_ENVELOPE_RPCNT_SHIFT = 9,
- AUDIO_ENVELOPE_ADDR_HIGH = 0x007,
- AUDIO_EADDR_HIGH_MASK = 0x003f,
- AUDIO_IRQ_EN_MASK = 0x0040,
- AUDIO_IRQ_ADDR_MASK = 0xff80,
- AUDIO_IRQ_ADDR_SHIFT = 7,
+ AUDIO_ENVELOPE_ADDR_HIGH = 0x007,
+ AUDIO_EADDR_HIGH_MASK = 0x003f,
+ AUDIO_IRQ_EN_MASK = 0x0040,
+ AUDIO_IRQ_ADDR_MASK = 0xff80,
+ AUDIO_IRQ_ADDR_SHIFT = 7,
- AUDIO_ENVELOPE_ADDR = 0x008,
- AUDIO_WAVE_DATA_PREV = 0x009,
+ AUDIO_ENVELOPE_ADDR = 0x008,
+ AUDIO_WAVE_DATA_PREV = 0x009,
- AUDIO_ENVELOPE_LOOP_CTRL = 0x00a,
- AUDIO_EAOFFSET_MASK = 0x01ff,
- AUDIO_RAMPDOWN_OFFSET_MASK = 0xfe00,
- AUDIO_RAMPDOWN_OFFSET_SHIFT = 9,
+ AUDIO_ENVELOPE_LOOP_CTRL = 0x00a,
+ AUDIO_EAOFFSET_MASK = 0x01ff,
+ AUDIO_RAMPDOWN_OFFSET_MASK = 0xfe00,
+ AUDIO_RAMPDOWN_OFFSET_SHIFT = 9,
- AUDIO_WAVE_DATA = 0x00b,
+ AUDIO_WAVE_DATA = 0x00b,
- AUDIO_ADPCM_SEL = 0x00d,
- AUDIO_ADPCM_SEL_MASK = 0xfe00,
- AUDIO_POINT_NUMBER_MASK = 0x7e00,
- AUDIO_POINT_NUMBER_SHIFT = 9,
- AUDIO_ADPCM36_MASK = 0x8000,
+ AUDIO_ADPCM_SEL = 0x00d,
+ AUDIO_ADPCM_SEL_MASK = 0xfe00,
+ AUDIO_POINT_NUMBER_MASK = 0x7e00,
+ AUDIO_POINT_NUMBER_SHIFT = 9,
+ AUDIO_ADPCM36_MASK = 0x8000,
- AUDIO_PHASE_HIGH = 0x200,
- AUDIO_PHASE_HIGH_MASK = 0x0007,
+ AUDIO_PHASE_HIGH = 0x200,
+ AUDIO_PHASE_HIGH_MASK = 0x0007,
- AUDIO_PHASE_ACCUM_HIGH = 0x201,
- AUDIO_PHASE_ACCUM_HIGH_MASK = 0x0007,
+ AUDIO_PHASE_ACCUM_HIGH = 0x201,
+ AUDIO_PHASE_ACCUM_HIGH_MASK = 0x0007,
- AUDIO_TARGET_PHASE_HIGH = 0x202,
+ AUDIO_TARGET_PHASE_HIGH = 0x202,
AUDIO_TARGET_PHASE_HIGH_MASK= 0x0007,
- AUDIO_RAMP_DOWN_CLOCK = 0x203,
- AUDIO_RAMP_DOWN_CLOCK_MASK = 0x0007,
+ AUDIO_RAMP_DOWN_CLOCK = 0x203,
+ AUDIO_RAMP_DOWN_CLOCK_MASK = 0x0007,
- AUDIO_PHASE = 0x204,
- AUDIO_PHASE_ACCUM = 0x205,
- AUDIO_TARGET_PHASE = 0x206,
+ AUDIO_PHASE = 0x204,
+ AUDIO_PHASE_ACCUM = 0x205,
+ AUDIO_TARGET_PHASE = 0x206,
- AUDIO_PHASE_CTRL = 0x207,
- AUDIO_PHASE_OFFSET_MASK = 0x0fff,
- AUDIO_PHASE_SIGN_MASK = 0x1000,
- AUDIO_PHASE_SIGN_SHIFT = 12,
- AUDIO_PHASE_TIME_STEP_MASK = 0xe000,
- AUDIO_PHASE_TIME_STEP_SHIFT = 13,
+ AUDIO_PHASE_CTRL = 0x207,
+ AUDIO_PHASE_OFFSET_MASK = 0x0fff,
+ AUDIO_PHASE_SIGN_MASK = 0x1000,
+ AUDIO_PHASE_SIGN_SHIFT = 12,
+ AUDIO_PHASE_TIME_STEP_MASK = 0xe000,
+ AUDIO_PHASE_TIME_STEP_SHIFT = 13,
- AUDIO_CHAN_OFFSET_MASK = 0xf0f,
+ AUDIO_CHAN_OFFSET_MASK = 0xf0f,
- AUDIO_CHANNEL_ENABLE = 0x400,
- AUDIO_CHANNEL_ENABLE_MASK = 0xffff,
+ AUDIO_CHANNEL_ENABLE = 0x400,
+ AUDIO_CHANNEL_ENABLE_MASK = 0xffff,
- AUDIO_MAIN_VOLUME = 0x401,
- AUDIO_MAIN_VOLUME_MASK = 0x007f,
+ AUDIO_MAIN_VOLUME = 0x401,
+ AUDIO_MAIN_VOLUME_MASK = 0x007f,
- AUDIO_CHANNEL_FIQ_ENABLE = 0x402,
- AUDIO_CHANNEL_FIQ_ENABLE_MASK = 0xffff,
+ AUDIO_CHANNEL_FIQ_ENABLE = 0x402,
+ AUDIO_CHANNEL_FIQ_ENABLE_MASK = 0xffff,
- AUDIO_CHANNEL_FIQ_STATUS = 0x403,
- AUDIO_CHANNEL_FIQ_STATUS_MASK = 0xffff,
+ AUDIO_CHANNEL_FIQ_STATUS = 0x403,
+ AUDIO_CHANNEL_FIQ_STATUS_MASK = 0xffff,
- AUDIO_BEAT_BASE_COUNT = 0x404,
- AUDIO_BEAT_BASE_COUNT_MASK = 0x07ff,
+ AUDIO_BEAT_BASE_COUNT = 0x404,
+ AUDIO_BEAT_BASE_COUNT_MASK = 0x07ff,
- AUDIO_BEAT_COUNT = 0x405,
- AUDIO_BEAT_COUNT_MASK = 0x3fff,
- AUDIO_BIS_MASK = 0x4000,
- AUDIO_BIE_MASK = 0x8000,
+ AUDIO_BEAT_COUNT = 0x405,
+ AUDIO_BEAT_COUNT_MASK = 0x3fff,
+ AUDIO_BIS_MASK = 0x4000,
+ AUDIO_BIE_MASK = 0x8000,
- AUDIO_ENVCLK0 = 0x406,
+ AUDIO_ENVCLK0 = 0x406,
- AUDIO_ENVCLK0_HIGH = 0x407,
- AUDIO_ENVCLK0_HIGH_MASK = 0xffff,
+ AUDIO_ENVCLK0_HIGH = 0x407,
+ AUDIO_ENVCLK0_HIGH_MASK = 0xffff,
- AUDIO_ENVCLK1 = 0x408,
+ AUDIO_ENVCLK1 = 0x408,
- AUDIO_ENVCLK1_HIGH = 0x409,
- AUDIO_ENVCLK1_HIGH_MASK = 0xffff,
+ AUDIO_ENVCLK1_HIGH = 0x409,
+ AUDIO_ENVCLK1_HIGH_MASK = 0xffff,
- AUDIO_ENV_RAMP_DOWN = 0x40a,
- AUDIO_ENV_RAMP_DOWN_MASK = 0xffff,
+ AUDIO_ENV_RAMP_DOWN = 0x40a,
+ AUDIO_ENV_RAMP_DOWN_MASK = 0xffff,
- AUDIO_CHANNEL_STOP = 0x40b,
- AUDIO_CHANNEL_STOP_MASK = 0xffff,
+ AUDIO_CHANNEL_STOP = 0x40b,
+ AUDIO_CHANNEL_STOP_MASK = 0xffff,
- AUDIO_CHANNEL_ZERO_CROSS = 0x40c,
- AUDIO_CHANNEL_ZERO_CROSS_MASK = 0xffff,
+ AUDIO_CHANNEL_ZERO_CROSS = 0x40c,
+ AUDIO_CHANNEL_ZERO_CROSS_MASK = 0xffff,
- AUDIO_CONTROL = 0x40d,
- AUDIO_CONTROL_MASK = 0x9fe8,
- AUDIO_CONTROL_SATURATE_MASK = 0x8000,
- AUDIO_CONTROL_SOFTCH_MASK = 0x1000,
- AUDIO_CONTROL_COMPEN_MASK = 0x0800,
- AUDIO_CONTROL_NOHIGH_MASK = 0x0400,
- AUDIO_CONTROL_NOINT_MASK = 0x0200,
- AUDIO_CONTROL_EQEN_MASK = 0x0100,
- AUDIO_CONTROL_VOLSEL_MASK = 0x00c0,
- AUDIO_CONTROL_VOLSEL_SHIFT = 6,
- AUDIO_CONTROL_FOF_MASK = 0x0020,
- AUDIO_CONTROL_INIT_MASK = 0x0008,
+ AUDIO_CONTROL = 0x40d,
+ AUDIO_CONTROL_MASK = 0x9fe8,
+ AUDIO_CONTROL_SATURATE_MASK = 0x8000,
+ AUDIO_CONTROL_SOFTCH_MASK = 0x1000,
+ AUDIO_CONTROL_COMPEN_MASK = 0x0800,
+ AUDIO_CONTROL_NOHIGH_MASK = 0x0400,
+ AUDIO_CONTROL_NOINT_MASK = 0x0200,
+ AUDIO_CONTROL_EQEN_MASK = 0x0100,
+ AUDIO_CONTROL_VOLSEL_MASK = 0x00c0,
+ AUDIO_CONTROL_VOLSEL_SHIFT = 6,
+ AUDIO_CONTROL_FOF_MASK = 0x0020,
+ AUDIO_CONTROL_INIT_MASK = 0x0008,
- AUDIO_COMPRESS_CTRL = 0x40e,
- AUDIO_COMPRESS_CTRL_PEAK_MASK = 0x8000,
- AUDIO_COMPRESS_CTRL_THRESHOLD_MASK = 0x7f00,
- AUDIO_COMPRESS_CTRL_THRESHOLD_SHIFT = 8,
- AUDIO_COMPRESS_CTRL_ATTSCALE_MASK = 0x00c0,
- AUDIO_COMPRESS_CTRL_ATTSCALE_SHIFT = 6,
- AUDIO_COMPRESS_CTRL_RELSCALE_MASK = 0x0030,
- AUDIO_COMPRESS_CTRL_RELSCALE_SHIFT = 4,
- AUDIO_COMPRESS_CTRL_DISZC_MASK = 0x0008,
- AUDIO_COMPRESS_CTRL_RATIO_MASK = 0x0007,
+ AUDIO_COMPRESS_CTRL = 0x40e,
+ AUDIO_COMPRESS_CTRL_PEAK_MASK = 0x8000,
+ AUDIO_COMPRESS_CTRL_THRESHOLD_MASK = 0x7f00,
+ AUDIO_COMPRESS_CTRL_THRESHOLD_SHIFT = 8,
+ AUDIO_COMPRESS_CTRL_ATTSCALE_MASK = 0x00c0,
+ AUDIO_COMPRESS_CTRL_ATTSCALE_SHIFT = 6,
+ AUDIO_COMPRESS_CTRL_RELSCALE_MASK = 0x0030,
+ AUDIO_COMPRESS_CTRL_RELSCALE_SHIFT = 4,
+ AUDIO_COMPRESS_CTRL_DISZC_MASK = 0x0008,
+ AUDIO_COMPRESS_CTRL_RATIO_MASK = 0x0007,
- AUDIO_CHANNEL_STATUS = 0x40f,
- AUDIO_CHANNEL_STATUS_MASK = 0xffff,
+ AUDIO_CHANNEL_STATUS = 0x40f,
+ AUDIO_CHANNEL_STATUS_MASK = 0xffff,
- AUDIO_WAVE_IN_L = 0x410,
+ AUDIO_WAVE_IN_L = 0x410,
- AUDIO_WAVE_IN_R = 0x411,
- AUDIO_SOFTIRQ_MASK = 0x8000,
- AUDIO_SOFTIRQ_EN_MASK = 0x4000,
- AUDIO_SOFT_PHASE_HIGH_MASK = 0x0070,
- AUDIO_SOFT_PHASE_HIGH_SHIFT = 4,
- AUDIO_FIFO_IRQ_THRESHOLD_MASK = 0x000f,
+ AUDIO_WAVE_IN_R = 0x411,
+ AUDIO_SOFTIRQ_MASK = 0x8000,
+ AUDIO_SOFTIRQ_EN_MASK = 0x4000,
+ AUDIO_SOFT_PHASE_HIGH_MASK = 0x0070,
+ AUDIO_SOFT_PHASE_HIGH_SHIFT = 4,
+ AUDIO_FIFO_IRQ_THRESHOLD_MASK = 0x000f,
- AUDIO_WAVE_OUT_L = 0x412,
- AUDIO_WAVE_OUT_R = 0x413,
+ AUDIO_WAVE_OUT_L = 0x412,
+ AUDIO_WAVE_OUT_R = 0x413,
- AUDIO_CHANNEL_REPEAT = 0x414,
- AUDIO_CHANNEL_REPEAT_MASK = 0xffff,
+ AUDIO_CHANNEL_REPEAT = 0x414,
+ AUDIO_CHANNEL_REPEAT_MASK = 0xffff,
- AUDIO_CHANNEL_ENV_MODE = 0x415,
- AUDIO_CHANNEL_ENV_MODE_MASK = 0xffff,
+ AUDIO_CHANNEL_ENV_MODE = 0x415,
+ AUDIO_CHANNEL_ENV_MODE_MASK = 0xffff,
- AUDIO_CHANNEL_TONE_RELEASE = 0x416,
- AUDIO_CHANNEL_TONE_RELEASE_MASK = 0xffff,
+ AUDIO_CHANNEL_TONE_RELEASE = 0x416,
+ AUDIO_CHANNEL_TONE_RELEASE_MASK = 0xffff,
- AUDIO_CHANNEL_ENV_IRQ = 0x417,
- AUDIO_CHANNEL_ENV_IRQ_MASK = 0xffff,
+ AUDIO_CHANNEL_ENV_IRQ = 0x417,
+ AUDIO_CHANNEL_ENV_IRQ_MASK = 0xffff,
- AUDIO_CHANNEL_PITCH_BEND = 0x418,
- AUDIO_CHANNEL_PITCH_BEND_MASK = 0xffff,
+ AUDIO_CHANNEL_PITCH_BEND = 0x418,
+ AUDIO_CHANNEL_PITCH_BEND_MASK = 0xffff,
- AUDIO_SOFT_PHASE = 0x419,
+ AUDIO_SOFT_PHASE = 0x419,
- AUDIO_ATTACK_RELEASE = 0x41a,
- AUDIO_RELEASE_TIME_MASK = 0x00ff,
- AUDIO_ATTACK_TIME_MASK = 0xff00,
- AUDIO_ATTACK_TIME_SHIFT = 8,
+ AUDIO_ATTACK_RELEASE = 0x41a,
+ AUDIO_RELEASE_TIME_MASK = 0x00ff,
+ AUDIO_ATTACK_TIME_MASK = 0xff00,
+ AUDIO_ATTACK_TIME_SHIFT = 8,
- AUDIO_EQ_CUTOFF10 = 0x41b,
- AUDIO_EQ_CUTOFF10_MASK = 0x7f7f,
+ AUDIO_EQ_CUTOFF10 = 0x41b,
+ AUDIO_EQ_CUTOFF10_MASK = 0x7f7f,
- AUDIO_EQ_CUTOFF32 = 0x41c,
- AUDIO_EQ_CUTOFF32_MASK = 0x7f7f,
+ AUDIO_EQ_CUTOFF32 = 0x41c,
+ AUDIO_EQ_CUTOFF32_MASK = 0x7f7f,
- AUDIO_EQ_GAIN10 = 0x41d,
- AUDIO_EQ_GAIN10_MASK = 0x7f7f,
+ AUDIO_EQ_GAIN10 = 0x41d,
+ AUDIO_EQ_GAIN10_MASK = 0x7f7f,
- AUDIO_EQ_GAIN32 = 0x41e,
- AUDIO_EQ_GAIN32_MASK = 0x7f7f
+ AUDIO_EQ_GAIN32 = 0x41e,
+ AUDIO_EQ_GAIN32_MASK = 0x7f7f
};
DECLARE_READ16_MEMBER(video_r);
diff --git a/src/devices/machine/sun4c_mmu.cpp b/src/devices/machine/sun4c_mmu.cpp
index 0f5272a1c43..08fae7b4aec 100644
--- a/src/devices/machine/sun4c_mmu.cpp
+++ b/src/devices/machine/sun4c_mmu.cpp
@@ -12,21 +12,21 @@
DEFINE_DEVICE_TYPE(SUN4C_MMU, sun4c_mmu_device, "sun4c_mmu", "Sun 4C MMU")
-#define LOG_PAGE_MAP (1U << 0)
-#define LOG_SEGMENT_MAP (1U << 1)
-#define LOG_INVALID_PTE (1U << 2)
-#define LOG_SYSTEM (1U << 3)
-#define LOG_CONTEXT (1U << 4)
-#define LOG_SYSTEM_ENABLE (1U << 5)
-#define LOG_BUSERROR (1U << 6)
-#define LOG_CACHE_TAGS (1U << 7)
-#define LOG_CACHE_DATA (1U << 8)
-#define LOG_UNKNOWN_SYSTEM (1U << 9)
-#define LOG_UNKNOWN_SEGMENT (1U << 10)
-#define LOG_TYPE0_TIMEOUT (1U << 11)
-#define LOG_UNKNOWN_SPACE (1U << 12)
-#define LOG_WRITE_PROTECT (1U << 13)
-#define LOG_ALL_ASI (1U << 14) // WARNING: Heavy!
+#define LOG_PAGE_MAP (1U << 0)
+#define LOG_SEGMENT_MAP (1U << 1)
+#define LOG_INVALID_PTE (1U << 2)
+#define LOG_SYSTEM (1U << 3)
+#define LOG_CONTEXT (1U << 4)
+#define LOG_SYSTEM_ENABLE (1U << 5)
+#define LOG_BUSERROR (1U << 6)
+#define LOG_CACHE_TAGS (1U << 7)
+#define LOG_CACHE_DATA (1U << 8)
+#define LOG_UNKNOWN_SYSTEM (1U << 9)
+#define LOG_UNKNOWN_SEGMENT (1U << 10)
+#define LOG_TYPE0_TIMEOUT (1U << 11)
+#define LOG_UNKNOWN_SPACE (1U << 12)
+#define LOG_WRITE_PROTECT (1U << 13)
+#define LOG_ALL_ASI (1U << 14) // WARNING: Heavy!
#define VERBOSE (0)
#include "logmacro.h"
@@ -447,11 +447,11 @@ template uint32_t sun4c_mmu_device::insn_data_r<sun4c_mmu_device::SUPER_DATA>(co
template <sun4c_mmu_device::insn_data_mode MODE>
uint32_t sun4c_mmu_device::insn_data_r(const uint32_t offset, const uint32_t mem_mask)
{
- // supervisor program fetches in boot state are special
- if (MODE == SUPER_INSN && m_fetch_bootrom)
- {
- return m_rom_ptr[offset & 0x1ffff];
- }
+ // supervisor program fetches in boot state are special
+ if (MODE == SUPER_INSN && m_fetch_bootrom)
+ {
+ return m_rom_ptr[offset & 0x1ffff];
+ }
// it's translation time
const uint32_t pmeg = m_curr_segmap_masked[(offset >> 16) & 0xfff];// & m_pmeg_mask;
diff --git a/src/devices/machine/sun4c_mmu.h b/src/devices/machine/sun4c_mmu.h
index 9852013504d..b97ec362181 100644
--- a/src/devices/machine/sun4c_mmu.h
+++ b/src/devices/machine/sun4c_mmu.h
@@ -143,8 +143,8 @@ protected:
bool m_page_valid[16384];
// Internal MAME device state
- uint8_t m_ctx_mask; // SS2 is sun4c but has 16 contexts; most have 8
- uint8_t m_pmeg_mask; // SS2 is sun4c but has 16384 PTEs; most have 8192
+ uint8_t m_ctx_mask; // SS2 is sun4c but has 16 contexts; most have 8
+ uint8_t m_pmeg_mask; // SS2 is sun4c but has 16384 PTEs; most have 8192
uint32_t m_ram_set_mask[4]; // Used for mirroring within 4 megabyte sets
uint32_t m_ram_set_base[4];
uint32_t m_populated_ram_words;
diff --git a/src/devices/machine/tms9914.cpp b/src/devices/machine/tms9914.cpp
index d2a90589e53..00fedd5db0c 100644
--- a/src/devices/machine/tms9914.cpp
+++ b/src/devices/machine/tms9914.cpp
@@ -20,15 +20,14 @@
#include "tms9914.h"
// Debugging
-#include "logmacro.h"
#define LOG_NOISY_MASK (LOG_GENERAL << 1)
#define LOG_NOISY(...) LOGMASKED(LOG_NOISY_MASK, __VA_ARGS__)
#define LOG_REG_MASK (LOG_NOISY_MASK << 1)
#define LOG_REG(...) LOGMASKED(LOG_REG_MASK, __VA_ARGS__)
#define LOG_INT_MASK (LOG_REG_MASK << 1)
#define LOG_INT(...) LOGMASKED(LOG_INT_MASK, __VA_ARGS__)
-#undef VERBOSE
-#define VERBOSE 0
+//#define VERBOSE (LOG_GENERAL)
+#include "logmacro.h"
// Bit manipulation
namespace {
@@ -716,20 +715,20 @@ void tms9914_device::update_fsm()
m_sh_vsts = true;
}
if (!get_signal(IEEE_488_NDAC)) {
-#if VERBOSE
- bool iscmd = m_signals[IEEE_488_ATN];
- char cmd[16] = "";
- if (iscmd) {
- uint8_t tmp = m_dio & 0x7f;
- if (tmp >= 0x20 && tmp <= 0x3f)
- snprintf(cmd, 16, "MLA%d", tmp & 0x1f);
- else if (tmp >= 0x40 && tmp <= 0x5f)
- snprintf(cmd, 16, "MTA%d", tmp & 0x1f);
- else if (tmp >= 0x60 && tmp <= 0x7f)
- snprintf(cmd, 16, "MSA%d", tmp & 0x1f);
+ if (VERBOSE & LOG_GENERAL) {
+ bool const iscmd = m_signals[IEEE_488_ATN];
+ char cmd[16] = "";
+ if (iscmd) {
+ uint8_t tmp = m_dio & 0x7f;
+ if (tmp >= 0x20 && tmp <= 0x3f)
+ snprintf(cmd, 16, "MLA%d", tmp & 0x1f);
+ else if (tmp >= 0x40 && tmp <= 0x5f)
+ snprintf(cmd, 16, "MTA%d", tmp & 0x1f);
+ else if (tmp >= 0x60 && tmp <= 0x7f)
+ snprintf(cmd, 16, "MSA%d", tmp & 0x1f);
+ }
+ LOG("%.6f TX %s %02X/%d %s\n" , machine().time().as_double() , m_signals[IEEE_488_ATN] ? "C" : "D", m_dio , m_signals[ IEEE_488_EOI ], cmd);
}
- LOG("%.6f TX %s %02X/%d %s\n" , machine().time().as_double() , m_signals[IEEE_488_ATN] ? "C" : "D", m_dio , m_signals[ IEEE_488_EOI ], cmd);
-#endif
m_sh_state = FSM_SH_SGNS;
}
break;
diff --git a/src/devices/sound/pokey.cpp b/src/devices/sound/pokey.cpp
index 7880de562d7..53ad7f26fdf 100644
--- a/src/devices/sound/pokey.cpp
+++ b/src/devices/sound/pokey.cpp
@@ -507,7 +507,7 @@ void pokey_device::step_keyboard()
if (m_IRQEN & IRQ_KEYBD)
{
/* last interrupt not acknowledged ? */
- if(m_IRQST & IRQ_KEYBD)
+ if (m_IRQST & IRQ_KEYBD)
m_SKSTAT |= SK_KBERR;
m_IRQST |= IRQ_KEYBD;
if (!m_irq_f.isnull())
@@ -546,18 +546,16 @@ void pokey_device::step_keyboard()
void pokey_device::step_pot()
{
- int pot;
-
- if( (m_SKCTL & SK_RESET) == 0)
+ if ((m_SKCTL & SK_RESET) == 0)
return;
uint8_t upd = 0;
m_pot_counter++;
- for (pot = 0; pot < 8; pot++)
+ for (int pot = 0; pot < 8; pot++)
{
if ((m_POTx[pot]<m_pot_counter) || (m_pot_counter == 228))
{
- upd |= (1<<pot);
+ upd |= (1 << pot);
/* latching is emulated in read */
}
}
@@ -574,14 +572,13 @@ void pokey_device::step_pot()
uint32_t pokey_device::step_one_clock(void)
{
- int ch, clk;
- uint32_t sum = 0;
- int clock_triggered[3] = {0,0,0};
- int base_clock = (m_AUDCTL & CLK_15KHZ) ? CLK_114 : CLK_28;
+ int const base_clock = (m_AUDCTL & CLK_15KHZ) ? CLK_114 : CLK_28;
- if( (m_SKCTL & SK_RESET) )
+ if (m_SKCTL & SK_RESET)
{
/* Clocks only count if we are not in a reset */
+ int clock_triggered[3] = {0,0,0};
+ int clk;
for (clk = 0; clk < 3; clk++)
{
m_clock_cnt[clk]++;
@@ -625,7 +622,7 @@ uint32_t pokey_device::step_one_clock(void)
/* do CHAN2 before CHAN1 because CHAN1 may set borrow! */
if (m_channel[CHAN2].check_borrow())
{
- int isJoined = (m_AUDCTL & CH12_JOINED);
+ bool const isJoined(m_AUDCTL & CH12_JOINED);
if (isJoined)
m_channel[CHAN1].reset_channel();
m_channel[CHAN2].reset_channel();
@@ -638,7 +635,7 @@ uint32_t pokey_device::step_one_clock(void)
if (m_channel[CHAN1].check_borrow())
{
- int isJoined = (m_AUDCTL & CH12_JOINED);
+ bool const isJoined(m_AUDCTL & CH12_JOINED);
if (isJoined)
m_channel[CHAN2].inc_chan();
else
@@ -652,7 +649,7 @@ uint32_t pokey_device::step_one_clock(void)
/* do CHAN4 before CHAN3 because CHAN3 may set borrow! */
if (m_channel[CHAN4].check_borrow())
{
- int isJoined = (m_AUDCTL & CH34_JOINED);
+ bool const isJoined(m_AUDCTL & CH34_JOINED);
if (isJoined)
m_channel[CHAN3].reset_channel();
m_channel[CHAN4].reset_channel();
@@ -668,7 +665,7 @@ uint32_t pokey_device::step_one_clock(void)
if (m_channel[CHAN3].check_borrow())
{
- int isJoined = (m_AUDCTL & CH34_JOINED);
+ bool const isJoined(m_AUDCTL & CH34_JOINED);
if (isJoined)
m_channel[CHAN4].inc_chan();
else
@@ -681,7 +678,8 @@ uint32_t pokey_device::step_one_clock(void)
m_channel[CHAN1].m_filter_sample = 1;
}
- for (ch = 0; ch < 4; ch++)
+ uint32_t sum = 0;
+ for (int ch = 0; ch < 4; ch++)
{
sum |= (((((m_channel[ch].m_output ^ m_channel[ch].m_filter_sample) || (m_channel[ch].m_AUDC & VOLUME_ONLY)) ? (m_channel[ch].m_AUDC & VOLUME_MASK) : 0 )) << (ch * 4));
}
@@ -793,7 +791,7 @@ READ8_MEMBER( pokey_device::read )
case POT0_C: case POT1_C: case POT2_C: case POT3_C:
case POT4_C: case POT5_C: case POT6_C: case POT7_C:
pot = offset & 7;
- if( m_ALLPOT & (1 << pot) )
+ if (m_ALLPOT & (1 << pot))
{
/* we have a value measured */
data = m_POTx[pot];
@@ -811,12 +809,12 @@ READ8_MEMBER( pokey_device::read )
* If the 2 least significant bits of SKCTL are 0, the ALLPOTs
* are disabled (SKRESET). Thanks to MikeJ for pointing this out.
****************************************************************/
- if( (m_SKCTL & SK_RESET) == 0)
+ if ((m_SKCTL & SK_RESET) == 0)
{
data = m_ALLPOT;
LOG(("POKEY '%s' ALLPOT internal $%02x (reset)\n", tag(), data));
}
- else if( !m_allpot_r_cb.isnull() )
+ else if (!m_allpot_r_cb.isnull())
{
m_ALLPOT = data = m_allpot_r_cb(offset);
LOG(("%s: POKEY '%s' ALLPOT callback $%02x\n", machine().describe_context(), tag(), data));
@@ -833,7 +831,7 @@ READ8_MEMBER( pokey_device::read )
break;
case RANDOM_C:
- if( m_AUDCTL & POLY9 )
+ if (m_AUDCTL & POLY9)
{
data = m_poly9[m_p9] & 0xff;
LOG_RAND(("POKEY '%s' rand9[$%05x]: $%02x\n", tag(), m_p9, data));
@@ -846,7 +844,7 @@ READ8_MEMBER( pokey_device::read )
break;
case SERIN_C:
- if( !m_serin_r_cb.isnull() )
+ if (!m_serin_r_cb.isnull())
m_SERIN = m_serin_r_cb(offset);
data = m_SERIN;
LOG(("POKEY '%s' SERIN $%02x\n", tag(), data));
@@ -880,7 +878,7 @@ READ8_MEMBER( pokey_device::read )
WRITE8_MEMBER( pokey_device::write )
{
- synchronize(SYNC_WRITE, (offset<<8) | data);
+ synchronize(SYNC_WRITE, (offset << 8) | data);
}
void pokey_device::write_internal(offs_t offset, uint8_t data)
@@ -1145,7 +1143,7 @@ void pokey_device::vol_init()
rTot = 0;
for (int i=0; i<4; i++)
{
- rTot += 1.0 / r_chan[(j>>(i*4)) & 0x0f];
+ rTot += 1.0 / r_chan[(j >> (i*4)) & 0x0f];
}
rTot = 1.0 / rTot;
m_voltab[j] = rTot;
diff --git a/src/devices/video/dp8350.cpp b/src/devices/video/dp8350.cpp
index 6d240c68793..a522220849e 100644
--- a/src/devices/video/dp8350.cpp
+++ b/src/devices/video/dp8350.cpp
@@ -66,12 +66,12 @@ DEFINE_DEVICE_TYPE(DP8367, dp8367_device, "dp8367", "DP8367 CRTC")
//-------------------------------------------------
dp835x_device::dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock,
- int char_width, int char_height, int chars_per_row, int rows_per_frame,
- int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1,
- int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0,
- int chars_per_line, int hsync_delay, int hsync_width, int vblank_stop,
- bool cursor_on_all_lines, int lbc_0_width, int hsync_serration,
- bool hsync_active, bool vsync_active, bool vblank_active)
+ int char_width, int char_height, int chars_per_row, int rows_per_frame,
+ int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1,
+ int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0,
+ int chars_per_line, int hsync_delay, int hsync_width, int vblank_stop,
+ bool cursor_on_all_lines, int lbc_0_width, int hsync_serration,
+ bool hsync_active, bool vsync_active, bool vblank_active)
: device_t(mconfig, type, tag, owner, clock)
, device_video_interface(mconfig, *this)
, m_char_width(char_width)
@@ -124,12 +124,12 @@ dp835x_device::dp835x_device(const machine_config &mconfig, device_type type, co
dp8350_device::dp8350_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
: dp835x_device(mconfig, DP8350, tag, owner, clock,
- 7, 10, 80, 24,
- 4, 10, 20,
- 30, 10, 72,
- 100, 0, 43, 1, // yes, the horizontal sync pulse is more than twice as long as the blanking period
- true, 4, 0,
- true, false, true)
+ 7, 10, 80, 24,
+ 4, 10, 20,
+ 30, 10, 72,
+ 100, 0, 43, 1, // yes, the horizontal sync pulse is more than twice as long as the blanking period
+ true, 4, 0,
+ true, false, true)
{
}
@@ -140,12 +140,12 @@ dp8350_device::dp8350_device(const machine_config &mconfig, const char *tag, dev
dp8367_device::dp8367_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
: dp835x_device(mconfig, DP8367, tag, owner, clock,
- 9, 15, 80, 26,
- 0, 19, 25,
- 38, 64, 108,
- 115, -16, 7, 1, // value of vblank_stop assumed
- true, 5, 0, // values assumed
- true, true, true)
+ 9, 15, 80, 26,
+ 0, 19, 25,
+ 38, 64, 108,
+ 115, -16, 7, 1, // value of vblank_stop assumed
+ true, 5, 0, // values assumed
+ true, true, true)
{
}
diff --git a/src/devices/video/dp8350.h b/src/devices/video/dp8350.h
index f202bc730e9..e8368c09c32 100644
--- a/src/devices/video/dp8350.h
+++ b/src/devices/video/dp8350.h
@@ -74,12 +74,12 @@ public:
protected:
// base type constructor
dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock,
- int char_width, int char_height, int chars_per_row, int rows_per_frame,
- int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1,
- int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0,
- int chars_per_line, int hsync_delay, int hsync_width, int vblank_stop,
- bool cursor_on_all_lines, int lbc_0_width, int hsync_serration,
- bool hsync_active, bool vsync_active, bool vblank_active);
+ int char_width, int char_height, int chars_per_row, int rows_per_frame,
+ int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1,
+ int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0,
+ int chars_per_line, int hsync_delay, int hsync_width, int vblank_stop,
+ bool cursor_on_all_lines, int lbc_0_width, int hsync_serration,
+ bool hsync_active, bool vsync_active, bool vblank_active);
// device-specific overrides
virtual void device_config_complete() override;
diff --git a/src/emu/dirtc.cpp b/src/emu/dirtc.cpp
index 0d5442fe6c2..20ebbbacef8 100644
--- a/src/emu/dirtc.cpp
+++ b/src/emu/dirtc.cpp
@@ -197,8 +197,8 @@ void device_rtc_interface::advance_days()
if (m_register[RTC_MONTH] > 0 && m_register[RTC_DAY] > DAYS_PER_MONTH[m_register[RTC_MONTH] - 1])
{
- if (m_register[RTC_MONTH] != 2 || m_register[RTC_DAY] != 29 || !rtc_feature_leap_year() ||
- (m_register[RTC_YEAR] % 4) != 0) {
+ if (m_register[RTC_MONTH] != 2 || m_register[RTC_DAY] != 29 || !rtc_feature_leap_year() || !(m_register[RTC_YEAR] % 4))
+ {
m_register[RTC_DAY] = 1;
m_register[RTC_MONTH]++;
}
diff --git a/src/emu/emuopts.cpp b/src/emu/emuopts.cpp
index 0f595a4b485..2a677dfd58b 100644
--- a/src/emu/emuopts.cpp
+++ b/src/emu/emuopts.cpp
@@ -389,7 +389,7 @@ namespace
if (!same_name)
result.push_back(image.brief_instance_name());
- if( image.instance_name() != image.cannonical_instance_name() )
+ if (image.instance_name() != image.cannonical_instance_name())
{
result.push_back(image.cannonical_instance_name());
if (!same_name)
diff --git a/src/mame/drivers/8080bw.cpp b/src/mame/drivers/8080bw.cpp
index 169088aeae8..1a1a28af5a8 100644
--- a/src/mame/drivers/8080bw.cpp
+++ b/src/mame/drivers/8080bw.cpp
@@ -1,5 +1,5 @@
// license:BSD-3-Clause
-// copyright-holders:Nicola Salmoria, Tormod Tjaberg, Mirko Buffoni,Lee Taylor, Valerio Verrando, Zsolt Vasvari,Aaron Giles,Jonathan Gevaryahu,hap,Robbbert
+// copyright-holders:Nicola Salmoria, Tormod Tjaberg, Mirko Buffoni, Lee Taylor, Valerio Verrando, Zsolt Vasvari, Aaron Giles, Jonathan Gevaryahu, hap, Robbbert
// thanks-to:Michael Strutts, Marco Cassili
/*****************************************************************************
@@ -207,6 +207,7 @@
#include "gunchamp.lh"
#include "shuttlei.lh"
#include "spacecom.lh"
+#include "yosakdon.lh"
/*******************************************************/
@@ -2719,11 +2720,11 @@ READ8_MEMBER(_8080bw_state::shuttlei_ff_r)
WRITE8_MEMBER(_8080bw_state::shuttlei_ff_w)
{
- /* bit 0 goes high when first coin inserted
- bit 1 also goes high when subsequent coins are inserted
- These may be for indicator lamps under the start buttons.
- bit 2 goes high while player 2 is playing */
-
+ /* bit 0 goes high when first coin inserted
+ bit 1 also goes high when subsequent coins are inserted
+ These may be for indicator lamps under the start buttons.
+ bit 2 goes high while player 2 is playing
+ */
m_flip_screen = BIT(data, 2) & BIT(ioport(CABINET_PORT_TAG)->read(), 0);
}
@@ -5209,7 +5210,7 @@ GAME( 1980, mlander, lrescue, lrescue, lrescue, _8080bw_state, empty_i
GAME( 1979, lrescuem, lrescue, lrescue, lrescue, _8080bw_state, empty_init, ROT270, "bootleg (Model Racing)", "Lunar Rescue (Model Racing bootleg, set 1)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
GAME( 1979, lrescuem2, lrescue, lrescue, lrescue, _8080bw_state, empty_init, ROT270, "bootleg (Model Racing)", "Lunar Rescue (Model Racing bootleg, set 2)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
GAME( 1979, desterth, lrescue, lrescue, lrescue, _8080bw_state, empty_init, ROT270, "bootleg", "Destination Earth (bootleg of Lunar Rescue)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
-GAMEL( 1980,escmars, lrescue, escmars, lrescue, _8080bw_state, empty_init, ROT270, "bootleg", "Escape from Mars (bootleg of Lunar Rescue)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND, layout_escmars )
+GAMEL(1980, escmars, lrescue, escmars, lrescue, _8080bw_state, empty_init, ROT270, "bootleg", "Escape from Mars (bootleg of Lunar Rescue)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND, layout_escmars )
GAME( 1979, schaser, 0, schaser, schaser, _8080bw_state, empty_init, ROT270, "Taito", "Space Chaser (set 1)", MACHINE_SUPPORTS_SAVE )
GAME( 1979, schasera, schaser, schaser, schaser, _8080bw_state, empty_init, ROT270, "Taito", "Space Chaser (set 2)", MACHINE_SUPPORTS_SAVE )
@@ -5265,8 +5266,8 @@ GAME( 1979, ozmawarsmr, ozmawars, invaders, ozmawars, mw8080bw_state, empty_i
GAME( 1979, spaceph, ozmawars, invaders, spaceph, mw8080bw_state, empty_init, ROT270, "bootleg? (Zilec Games)", "Space Phantoms (bootleg of Ozma Wars)", MACHINE_SUPPORTS_SAVE )
GAME( 1979, solfight, ozmawars, invaders, ozmawars, mw8080bw_state, empty_init, ROT270, "bootleg", "Solar Fight (bootleg of Ozma Wars)", MACHINE_SUPPORTS_SAVE )
-GAME( 1979, yosakdon, 0, yosakdon, yosakdon, _8080bw_state, empty_init, ROT270, "Wing", "Yosaku To Donbei (set 1)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
-GAME( 1979, yosakdona, yosakdon, yosakdon, yosakdon, _8080bw_state, empty_init, ROT270, "Wing", "Yosaku To Donbei (set 2)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND )
+GAMEL(1979, yosakdon, 0, yosakdon, yosakdon, _8080bw_state, empty_init, ROT270, "Wing", "Yosaku To Donbei (set 1)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND, layout_yosakdon )
+GAMEL(1979, yosakdona, yosakdon, yosakdon, yosakdon, _8080bw_state, empty_init, ROT270, "Wing", "Yosaku To Donbei (set 2)", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND, layout_yosakdon )
GAMEL(1979, shuttlei, 0, shuttlei, shuttlei, _8080bw_state, empty_init, ROT270, "Omori Electric Co., Ltd.", "Shuttle Invader", MACHINE_SUPPORTS_SAVE | MACHINE_IMPERFECT_SOUND, layout_shuttlei )
diff --git a/src/mame/drivers/alg.cpp b/src/mame/drivers/alg.cpp
index 027ca192c6a..96578f72bfa 100644
--- a/src/mame/drivers/alg.cpp
+++ b/src/mame/drivers/alg.cpp
@@ -4,21 +4,23 @@
American Laser Game Hardware
- Amiga 500 + sony ldp1450 laserdisc player
+ Amiga 500 + sony laserdisc player LDP-1450
+ (LDP-3300P for Zorton Brothers, LDP-1500 for Marbella Vice)
Games Supported:
Mad Dog McCree [3 versions]
Who Shot Johnny Rock? [2 versions]
- Mad Dog II: The Lost Gold [2 versions]
- Space Pirates
- Gallagher's Gallery
- Crime Patrol
+ Mad Dog II: The Lost Gold [4 versions]
+ Space Pirates [2 versions]
+ Gallagher's Gallery [2 versions]
+ Crime Patrol [3 versions]
Crime Patrol 2: Drug Wars [2 versions]
- The Last Bounty Hunter
- Fast Draw Showdown
+ The Last Bounty Hunter [2 versions]
+ Fast Draw Showdown [2 versions]
Platoon
- Zorton Brothers (Los Justicieros)
+ Zorton Brothers (Los Justicieros) [2 versions]
+ Marbella Vice
**************************************************************************************/
@@ -679,10 +681,31 @@ ROM_START( aplatoon )
DISK_IMAGE_READONLY( "platoon", 0, NO_DUMP )
ROM_END
+// zortonbr v1.01
+// ROM board labeled "PICMATIC LM6 04-01-92"
+// Uses Sony LaserMax LDP-3300P, a separate video encoder PCB with a Motorola MC1378B and a standard A500+ PCB.
+// ROM contains text: "Marbella Vice CopyRight 1994 Picmatic S.A. Program chief Brian Meitiner" (but it's Zorton Brothers)
+// References to linked libraries: Audio Master IV, AMAS II Version 1.1
+// Has a blacklist for high scores:
+// "FUCK SHIT CUNT PRICK PENUS BALLS PUTA JODER POLLA PUTO MAMON PICHA COJON TETA TETAS TITS CHULO CULO PENE PIJO LEFA LISTO"
ROM_START( zortonbr )
ALG_BIOS
ROM_REGION( 0x40000, "game_program", ROMREGION_ERASEFF )
+ ROM_LOAD16_BYTE( "zort_1-01_23-3-94_odd.u2", 0x000000, 0x10000, CRC(21e63949) SHA1(0a62ad108f8cfa00dc8f03dea2ff6f1b277e8d5d) )
+ ROM_LOAD16_BYTE( "zort_1-01_23-3-94_even.u3", 0x000001, 0x10000, CRC(6a051c6a) SHA1(f8daafab068fef57e47287bd72be860b84e2e75c) )
+
+ ROM_REGION( 0x00800, "unused_nvram", ROMREGION_ERASEFF ) //NVRAM, unused
+ ROM_LOAD( "zort_mk48z02b.u13", 0x0000, 0x0800, CRC(45b064a9) SHA1(f446be2b0e3929e182b9f97989c30b3ee308c103) )
+
+ DISK_REGION( "laserdisc" )
+ DISK_IMAGE_READONLY( "zortonbr", 0, NO_DUMP )
+ROM_END
+
+ROM_START( zortonbr_100 )
+ ALG_BIOS
+
+ ROM_REGION( 0x40000, "game_program", ROMREGION_ERASEFF )
ROM_LOAD16_BYTE( "zb_u2.bin", 0x000000, 0x10000, CRC(938b25cb) SHA1(d0114bbc588dcfce6a469013d0e35afb93e38af5) )
ROM_LOAD16_BYTE( "zb_u3.bin", 0x000001, 0x10000, CRC(f59cfc4a) SHA1(9fadf7f1e23d6b4e828bf2b3de919d087c690a3f) )
@@ -853,5 +876,6 @@ GAME( 1995, fastdraw_130, fastdraw, alg_r2, alg_2p, alg_state, init_palr6,
GAME( 199?, aplatoon, alg_bios, alg_r2, alg, alg_state, init_aplatoon, ROT0, "Nova?", "Platoon V.3.1 US", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_IMPERFECT_GRAPHICS )
/* Web Picmatic games PAL tv standard, own rom board */
-GAME( 1993, zortonbr, alg_bios, picmatic, alg, alg_state, init_pal, ROT0, "Web Picmatic", "Zorton Brothers (Los Justicieros)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1994, zortonbr, alg_bios, picmatic, alg, alg_state, init_pal, ROT0, "Web Picmatic", "Zorton Brothers v1.01 (Los Justicieros)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_IMPERFECT_GRAPHICS )
+GAME( 1993, zortonbr_100, zortonbr, picmatic, alg, alg_state, init_pal, ROT0, "Web Picmatic", "Zorton Brothers v1.00 (Los Justicieros)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_IMPERFECT_GRAPHICS )
GAME( 1994, marvice, alg_bios, picmatic, alg, alg_state, init_pal, ROT0, "Web Picmatic", "Marbella Vice", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_IMPERFECT_GRAPHICS )
diff --git a/src/mame/drivers/atetris.cpp b/src/mame/drivers/atetris.cpp
index 846d2785db9..b3d100fbbd9 100644
--- a/src/mame/drivers/atetris.cpp
+++ b/src/mame/drivers/atetris.cpp
@@ -484,7 +484,7 @@ ROM_START( atetrisb2 )
ROM_LOAD( "b-gal16v8-b.bin", 0x117, 0x117, CRC(b1dfab0f) SHA1(e9e4db5459617a35a13df4b7a4586dd1b7be04ac) ) // sub PCB - Same content as "a"
ROM_LOAD( "c-gal16v8-b.bin", 0x22e, 0x117, CRC(e1a9db0b) SHA1(5bbac24e37a4d9b8a1387054722fa35478ca7941) ) // sub PCB
ROM_LOAD( "1-pal16l8-a.3g" , 0x345, 0x104, CRC(dcf0d2fe) SHA1(0496acaa605ec5008b110c387136bbc714441384) ) // main PCB - Found also as GAL16v8 on some PCBs
- ROM_LOAD( "2-pal16r4-a.3r" , 0x449, 0x104, CRC(d71bdf27) SHA1(cc3503cb037de344fc353886f3492601638c9d45) ) // main PCB
+ ROM_LOAD( "2-pal16r4-a.3r" , 0x449, 0x104, CRC(d71bdf27) SHA1(cc3503cb037de344fc353886f3492601638c9d45) ) // main PCB
ROM_LOAD( "3-pal16r4-a.8p" , 0x54D, 0x104, CRC(e007edf2) SHA1(4f1bc31abd64e402edb4c900ddb21f258d6782c8) ) // main PCB - Found also as GAL16v8 on some PCBs
ROM_LOAD( "4-pal16l8-a.9n" , 0x651, 0x104, CRC(3630e734) SHA1(a29dc202ffc75ac48815115b85e984fc0c9d5b59) ) // main PCB - Found also as GAL16v8 on some PCBs
ROM_LOAD( "5-pal16l8-a.9m" , 0x755, 0x104, CRC(53b64be1) SHA1(2bf712b766541c90c38c0810ee16848e448c5205) ) // main PCB - Found also as GAL16v8 on some PCBs
@@ -569,7 +569,7 @@ H |74LS04 PAL16R8 ___________ | | | UN |74LS161 |
I |74LS32 74LS373 |__________| 74LS32 | PU |PAL16L8 |
| __________ 74LS04 | LA | |
J |74LS374 74LS357 | X2804AP | 74LS257 74LS138 | TED |PAL16?? |
- |____________ |_________| 74LS257 74LS257 | | |
+ |____________ |_________| 74LS257 74LS257 | | |
K ||D3 27PC256 | |_____|74LS161 |
||___________| 74LS245 74LS245 |
L |________________ _______________ 74LS257 74LS74 74LS161 |
diff --git a/src/mame/drivers/brkthru.cpp b/src/mame/drivers/brkthru.cpp
index 5c25de98f35..c148a822af2 100644
--- a/src/mame/drivers/brkthru.cpp
+++ b/src/mame/drivers/brkthru.cpp
@@ -553,7 +553,7 @@ ROM_START( brkthruj )
ROM_LOAD( "brkthru.5", 0x8000, 0x8000, CRC(c309435f) SHA1(82914004c2b169a7c31aa49af83a699ebbc7b33f) )
ROM_END
-// Tecfri PCB with Data East license.
+// Tecfri PCB with Data East license.
// Although only program ROM "8.bin" is marked as BAD_DUMP, it would be better to redump all program ROMs, to be 100% sure it's a good set.
ROM_START( brkthrut )
ROM_REGION( 0x20000, "maincpu", 0 ) /* 64k for main CPU + 64k for banked ROMs */
@@ -569,7 +569,7 @@ ROM_START( brkthrut )
/* background */
/* we do a lot of scatter loading here, to place the data in a format */
/* which can be decoded by MAME's standard functions */
- ROM_LOAD( "2.bin", 0x00000, 0x4000, CRC(920cc56a) SHA1(c75806691073f1f3bd54dcaca4c14155ecf4471d) ) /* bitplanes 1,2 for bank 1,2 */ /* Same as parent */
+ ROM_LOAD( "2.bin", 0x00000, 0x4000, CRC(920cc56a) SHA1(c75806691073f1f3bd54dcaca4c14155ecf4471d) ) /* bitplanes 1,2 for bank 1,2 */ /* Same as parent */
ROM_CONTINUE( 0x08000, 0x4000 ) /* bitplanes 1,2 for bank 3,4 */
ROM_LOAD( "1.bin", 0x10000, 0x4000, CRC(6c47dc43) SHA1(3274fb8ddf0e0c91f5796677255ade78e3b3f9d6) ) /* bitplanes 1,2 for bank 5,6 */
ROM_CONTINUE( 0x18000, 0x4000 ) /* bitplanes 1,2 for bank 7,8 */
diff --git a/src/mame/drivers/combatsc.cpp b/src/mame/drivers/combatsc.cpp
index 28712bec092..2fe86e2fe93 100644
--- a/src/mame/drivers/combatsc.cpp
+++ b/src/mame/drivers/combatsc.cpp
@@ -666,7 +666,7 @@ MACHINE_START_MEMBER(combatsc_state,combatsc)
save_pointer(NAME(m_page[0]),0x2000);
save_pointer(NAME(m_page[1]),0x2000);
save_pointer(NAME(m_scrollram0), 0x40);
- save_pointer(NAME(m_scrollram1), 0x40);
+ save_pointer(NAME(m_scrollram1), 0x40);
}
MACHINE_START_MEMBER(combatsc_state,combatscb)
diff --git a/src/mame/drivers/cps1.cpp b/src/mame/drivers/cps1.cpp
index f9845ef0642..f5b40780cba 100644
--- a/src/mame/drivers/cps1.cpp
+++ b/src/mame/drivers/cps1.cpp
@@ -6651,6 +6651,67 @@ ROM_START( sf2em )
ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) )
ROM_END
+/* B-Board 89625B-1 */
+ROM_START( sf2en )
+ ROM_REGION( CODE_SIZE, "maincpu", 0 ) /* 68000 code, all 27c010 */
+ ROM_LOAD16_BYTE( "epr-b-05.12f", 0x00000, 0x20000, CRC(bc02c14c) SHA1(83198317c3838d9a031f78c866fe690d185647f6) )
+ ROM_LOAD16_BYTE( "epr-b-09.12h", 0x00001, 0x20000, CRC(1c1266b3) SHA1(756f54e82305af6b4374b748d486ae587bf7571b) )
+ ROM_LOAD16_BYTE( "epr-b-06.13f", 0x40000, 0x20000, CRC(8b8221e6) SHA1(98d143943ea830a046f0f799b1cf27cc4024729b) )
+ ROM_LOAD16_BYTE( "epr-b-10.13h", 0x40001, 0x20000, CRC(2d42d82a) SHA1(4a1f23efef6ae6fe4bebd475f7429cf8ae291adf) )
+ ROM_LOAD16_BYTE( "epr-b-03.10f", 0x80000, 0x20000, CRC(852e10ec) SHA1(a39e0feac1ba9db209aae89b1d33a3a6a1bec2e1) )
+ ROM_LOAD16_BYTE( "epr-b-07.10h", 0x80001, 0x20000, CRC(3b075de1) SHA1(8dcadee5bbf8c91c60d6775d107543fb5e36d75d) )
+ ROM_LOAD16_BYTE( "epr-b-04.11f", 0xc0000, 0x20000, CRC(fdd0b5c1) SHA1(af9051d77f8e7039ea9b55482fcdbb0bad8bb63c) )
+ ROM_LOAD16_BYTE( "epr-b-08.11h", 0xc0001, 0x20000, CRC(db66b127) SHA1(cbf6aba28e24d5a7cd73733ee4c04ddc5e15e2a7) )
+
+ ROM_REGION( 0x600000, "gfx", 0 ) // all 27c020, data matches parent, but arranged differently
+ ROMX_LOAD( "epr-b-18.5e", 0x000000, 0x40000, CRC(88f3485a) SHA1(12df3a823a29eb5cc69993015108cb3da2c961f2) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-13.5c", 0x000001, 0x40000, CRC(63d63e0c) SHA1(5ed5cad35663d0fad37b917685c59f7f27fa434f) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-24.8h", 0x000002, 0x40000, CRC(25ae23bc) SHA1(b728cc97d656415fb89bcf4416d7309639c31e8c) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-23.8f", 0x000003, 0x40000, CRC(e5819676) SHA1(655d148a1b5adbe56008ba992fee0db8bb3be639) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-07.4b", 0x000004, 0x40000, CRC(84afb959) SHA1(ff8f3fb39203d229552649b09046a509aa399b7d) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-01.4a", 0x000005, 0x40000, CRC(ab21635d) SHA1(c6294b06c482a43cc1736674b0c1bc790da8cc8c) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-10.9b", 0x000006, 0x40000, CRC(2ce56f9f) SHA1(5bd23823df52aeff8e84a6eb3199a5e75f38cd42) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-04.9a", 0x000007, 0x40000, CRC(0ad7fb2b) SHA1(51265b331cbbe9d133274bafdbf043151240a20d) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-19.8e", 0x200000, 0x40000, CRC(031525cc) SHA1(65e280607c058cf9c005a6fc809ed375d379c0bf) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-14.8c", 0x200001, 0x40000, CRC(c97046a5) SHA1(88c7becaa2713c85e22ddd3e2305770525a9132b) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-21.10e", 0x200002, 0x40000, CRC(acbbdb09) SHA1(5d25f407c99727d166bcda570047cadd162f181d) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-16.10c", 0x200003, 0x40000, CRC(fa6f32d9) SHA1(e845365fe3af2f585f0a5d78dbedb97726da1a50) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-08.7b", 0x200004, 0x40000, CRC(14756473) SHA1(5ae69385cc77466404718974516bb6e87c03c11c) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-02.7a", 0x200005, 0x40000, CRC(ee3d878a) SHA1(624a18322d88fc4983f0008e1c8b21ed75f34ffc) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-11.11b", 0x200006, 0x40000, CRC(dbbfd400) SHA1(fc25928b6ed025fa2397d924bae93fd28a4e728f) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-05.11a", 0x200007, 0x40000, CRC(37635e97) SHA1(b4e5dd6e93174af76aaeeb47471ded0d0bc253e2) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-20.9e", 0x400000, 0x40000, CRC(27cae573) SHA1(f4aba951e8c5452f7d25f5117df4c1370c1790f9) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-15.9c", 0x400001, 0x40000, CRC(14e46ab1) SHA1(56c04199f03c2929e479f820c40fddbd0fc29e1d) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-22.11e", 0x400002, 0x40000, CRC(f241f0c7) SHA1(6fc89c1a83b7043e989c03bdad411b3e2a688528) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-17.11c", 0x400003, 0x40000, CRC(f187086b) SHA1(90966690d1fe415f73aaff77a029205b34dbb7e4) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-09.8b", 0x400004, 0x40000, CRC(4894aa8f) SHA1(33c8406550eb8ed1489686924e34c906329445f3) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-03.8a", 0x400005, 0x40000, CRC(e8877e9d) SHA1(6401ef0dbf88c8f402e49c1499123e60669bd9d5) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-12.12b", 0x400006, 0x40000, CRC(c9d4ed76) SHA1(c79ab721cb7ca3769e99e8db256e2ee0d9df7e09) , ROM_SKIP(7) )
+ ROMX_LOAD( "epr-b-06.12a", 0x400007, 0x40000, CRC(67dcc295) SHA1(0bcec5d2dcd7e3423a577eeb458b5f7cff3c571c) , ROM_SKIP(7) )
+
+ ROM_REGION( 0x18000, "audiocpu", 0 ) /* 64k for the audio CPU (+banks), data matches parent */
+ ROM_LOAD( "27c512.13b", 0x00000, 0x08000, CRC(a4823a1b) SHA1(7b6bf59dfd578bfbbdb64c27988796783442d659) ) // not labeled
+ ROM_CONTINUE( 0x10000, 0x08000 )
+
+ ROM_REGION( 0x40000, "oki", 0 ) /* Samples, 27c010, data matches parent */
+ ROM_LOAD( "epr-b-01.12c", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) )
+ ROM_LOAD( "epr-b-02.13c", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) )
+
+ ROM_REGION( 0x0200, "aboardplds", 0 )
+ ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) )
+ ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) )
+ ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) )
+ ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) )
+ ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) )
+
+ ROM_REGION( 0x0200, "bboardplds", 0 )
+ ROM_LOAD( "stf29.1a", 0x0000, 0x0117, CRC(043309c5) SHA1(f6b9610c9f896c495041ba56a654776a521c356b) ) // not labeled
+ ROM_LOAD( "iob1.11d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) )
+
+ ROM_REGION( 0x0200, "cboardplds", 0 )
+ ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) )
+ROM_END
+
/* B-Board 90629B-2 */
ROM_START( sf2ua )
ROM_REGION( CODE_SIZE, "maincpu", 0 ) /* 68000 code */
@@ -13099,6 +13160,7 @@ GAME( 1991, sf2eb, sf2, cps1_10MHz, sf2, cps_state, init_cps1,
GAME( 1991, sf2ed, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (World 910318)", MACHINE_SUPPORTS_SAVE ) // "ETC"
GAME( 1991, sf2ee, sf2, cps1_10MHz, sf2, cps_state, init_sf2ee, ROT0, "Capcom", "Street Fighter II: The World Warrior (World 910228)", MACHINE_SUPPORTS_SAVE ) // "ETC"
GAME( 1991, sf2em, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (World 910129)", MACHINE_SUPPORTS_SAVE ) // "ETC"
+GAME( 1991, sf2en, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (World 910204)", MACHINE_SUPPORTS_SAVE ) // "ETC"
GAME( 1991, sf2ua, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (USA 910206)", MACHINE_SUPPORTS_SAVE )
GAME( 1991, sf2ub, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (USA 910214)", MACHINE_SUPPORTS_SAVE )
GAME( 1991, sf2uc, sf2, cps1_10MHz, sf2, cps_state, init_cps1, ROT0, "Capcom", "Street Fighter II: The World Warrior (USA 910306)", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/cps2.cpp b/src/mame/drivers/cps2.cpp
index a3dcc202f16..277b6d6e4db 100644
--- a/src/mame/drivers/cps2.cpp
+++ b/src/mame/drivers/cps2.cpp
@@ -8146,6 +8146,42 @@ ROM_START( ssf2tbr1 )
ROM_LOAD( "ssf2tb.key", 0x000000, 0x000014, CRC(1ecc92b2) SHA1(22a3e7787225915833ffdef6ed2a896b079fc2f1) )
ROM_END
+ROM_START( ssf2tbu )
+ ROM_REGION( CODE_SIZE, "maincpu", 0 ) /* 68000 code */
+ ROM_LOAD16_WORD_SWAP( "ssfu.03t", 0x000000, 0x80000, CRC(4635b35e) SHA1(e4438812c7424d28f1caef9c2e19bc68aba81c43) )
+ ROM_LOAD16_WORD_SWAP( "ssfu.04t", 0x080000, 0x80000, CRC(2630b3dd) SHA1(c5f84fb2e93d3a4dbce6ec33cf6dae3513957837) )
+ ROM_LOAD16_WORD_SWAP( "ssfu.05t", 0x100000, 0x80000, CRC(c0293c97) SHA1(2f322e59364b9c030a3a163dc5b38778e4c7ba49) )
+ ROM_LOAD16_WORD_SWAP( "ssfu.06t", 0x180000, 0x80000, CRC(aaa33888) SHA1(c051a03c0dc55b1d16dc49ec8e4adfb5e6347c00) )
+ ROM_LOAD16_WORD_SWAP( "ssfu.07t", 0x200000, 0x80000, CRC(44c54534) SHA1(9bf7775e91b4d7dcfa397717b777798d105b02ff) )
+
+ ROM_REGION( 0xc00000, "gfx", 0 )
+ ROMX_LOAD( "ssf.13m", 0x000000, 0x200000, CRC(cf94d275) SHA1(bf2a6d98a656d1cb5734da7836686242d3211137) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.15m", 0x000002, 0x200000, CRC(5eb703af) SHA1(4b302dbb66e8a5c2ad92798699391e981bada427) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.17m", 0x000004, 0x200000, CRC(ffa60e0f) SHA1(b21b1c749a8241440879bf8e7cb33968ccef97e5) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.19m", 0x000006, 0x200000, CRC(34e825c5) SHA1(4d320fc96d1ef0b9928a8ce801734245a4c097a5) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.14m", 0x800000, 0x100000, CRC(b7cc32e7) SHA1(0f4d26af338dab5dce5b7b34d32ad0c573434ace) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.16m", 0x800002, 0x100000, CRC(8376ad18) SHA1(f4456833fb396e6501f4174c0fe5fd63ea40a188) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.18m", 0x800004, 0x100000, CRC(f5b1b336) SHA1(4b060501e56b9d61294748da5387cdae5280ec4d) , ROM_GROUPWORD | ROM_SKIP(6) )
+ ROMX_LOAD( "ssf.20m", 0x800006, 0x100000, CRC(459d5c6b) SHA1(32b11ba7a12004aff810d719bff7508204c7b7c0) , ROM_GROUPWORD | ROM_SKIP(6) )
+
+ ROM_REGION( QSOUND_SIZE, "audiocpu", 0 ) /* 64k for the audio CPU (+banks) */
+ ROM_LOAD( "ssf.01", 0x00000, 0x08000, CRC(eb247e8c) SHA1(24296c18d9b1136d69712bf1c9d9d15463041e83) )
+ ROM_CONTINUE( 0x10000, 0x18000 )
+
+ ROM_REGION( 0x400000, "qsound", 0 ) /* QSound samples */
+ ROM_LOAD( "ssf.q01", 0x000000, 0x080000, CRC(a6f9da5c) SHA1(6d19f83a01bd25b838d5c2871f7964529d926c98) )
+ ROM_LOAD( "ssf.q02", 0x080000, 0x080000, CRC(8c66ae26) SHA1(32a82aee6ed4480e5a990f9af161734c7c0a1403) )
+ ROM_LOAD( "ssf.q03", 0x100000, 0x080000, CRC(695cc2ca) SHA1(c2675f0233608b76de528d2a6ef19846d1348060) )
+ ROM_LOAD( "ssf.q04", 0x180000, 0x080000, CRC(9d9ebe32) SHA1(9b26329370041374f1a90b479a172d2bc2801c4d) )
+ ROM_LOAD( "ssf.q05", 0x200000, 0x080000, CRC(4770e7b7) SHA1(0e764f0befb9227b0b36508d8ca8ec9be31bcb05) )
+ ROM_LOAD( "ssf.q06", 0x280000, 0x080000, CRC(4e79c951) SHA1(1144781d7dc57ef8a6458d982f5c91548ff59e27) )
+ ROM_LOAD( "ssf.q07", 0x300000, 0x080000, CRC(cdd14313) SHA1(ebe767a9d4b51dba4282fa0a36a546a88620dd59) )
+ ROM_LOAD( "ssf.q08", 0x380000, 0x080000, CRC(6f5a088c) SHA1(6c0b4690479647a99d76335f174be8455b4ff118) )
+
+ ROM_REGION( 0x20, "key", 0 )
+ ROM_LOAD( "ssf2tbu.key", 0x000000, 0x000014, CRC(1da3ccf3) SHA1(d740581acdaccbc75308f0a8c53a3a910dc6a10f) )
+ROM_END
+
ROM_START( ssf2tbj )
ROM_REGION( CODE_SIZE, "maincpu", 0 ) /* 68000 code */
ROM_LOAD16_WORD_SWAP( "ssftj.03b", 0x000000, 0x80000, CRC(e78a3433) SHA1(c5a1f209e467f8f5a791b2d2f184e71650c8c9df) )
@@ -9973,6 +10009,7 @@ GAME( 1993, ssf2jr2, ssf2, cps2, cps2_2p6b, cps2_state, init_cps2, RO
GAME( 1993, ssf2h, ssf2, cps2, cps2_2p6b, cps2_state, init_cps2, ROT0, "Capcom", "Super Street Fighter II: The New Challengers (Hispanic 930911)", MACHINE_SUPPORTS_SAVE )
GAME( 1993, ssf2tb, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (World 931119)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
GAME( 1993, ssf2tbr1, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (World 930911)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
+GAME( 1993, ssf2tbu, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (USA 930911)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
GAME( 1993, ssf2tbj, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (Japan 931005)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
GAME( 1993, ssf2tbj1, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (Japan 930911)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
GAME( 1993, ssf2tba, ssf2, cps2, cps2_2p6b, cps2_state, init_ssf2tb, ROT0, "Capcom", "Super Street Fighter II: The Tournament Battle (Asia 931005)", MACHINE_SUPPORTS_SAVE | MACHINE_NODEVICE_LAN ) // works, but not in tournament mode
diff --git a/src/mame/drivers/cps3.cpp b/src/mame/drivers/cps3.cpp
index fb7118533be..a18a7469f80 100644
--- a/src/mame/drivers/cps3.cpp
+++ b/src/mame/drivers/cps3.cpp
@@ -1050,8 +1050,8 @@ uint32_t cps3_state::screen_update_cps3(screen_device &screen, bitmap_rgb32 &bit
// decode_charram();
/* registers are normally 002a006f 01ef01c6
- widescreen mode = 00230076 026501c6
- only SFIII2 uses widescreen, I don't know exactly which register controls it */
+ widescreen mode = 00230076 026501c6
+ only SFIII2 uses widescreen, I don't know exactly which register controls it */
if (((m_fullscreenzoom[1] & 0xffff0000) >> 16) == 0x0265)
{
if (m_screenwidth != 496)
@@ -1154,7 +1154,7 @@ uint32_t cps3_state::screen_update_cps3(screen_device &screen, bitmap_rgb32 &bit
int tilemapnum = ((value3 & 0x00000030) >> 4);
/* Urgh, the startline / endline seem to be direct screen co-ordinates regardless of fullscreen zoom
- which probably means the fullscreen zoom is applied when rendering everything, not aftewards */
+ which probably means the fullscreen zoom is applied when rendering everything, not aftewards */
if (bg_drawn[tilemapnum] == 0)
{
@@ -1288,10 +1288,10 @@ uint32_t cps3_state::screen_update_cps3(screen_device &screen, bitmap_rgb32 &bit
}
/*
- SSRAM 0x0000 - 0x1fff tilemap layout bank 0
- 0x2000 - 0x3fff tilemap layout bank 1
- 0x4000 - 0x7fff rowscroll (banked?)
- 0x8000 - 0xffff tile character definitions
+ SSRAM 0x0000 - 0x1fff tilemap layout bank 0
+ 0x2000 - 0x3fff tilemap layout bank 1
+ 0x4000 - 0x7fff rowscroll (banked?)
+ 0x8000 - 0xffff tile character definitions
*/
diff --git a/src/mame/drivers/crystal.cpp b/src/mame/drivers/crystal.cpp
index 43349c843d4..7f8e8326e6f 100644
--- a/src/mame/drivers/crystal.cpp
+++ b/src/mame/drivers/crystal.cpp
@@ -414,9 +414,8 @@ IRQ_CALLBACK_MEMBER(crystal_state::icallback)
{
address_space &space = m_maincpu->space(AS_PROGRAM);
uint32_t IntPend = space.read_dword(0x01800c0c);
- int i;
- for (i = 0; i < 32; ++i)
+ for (int i = 0; i < 32; ++i)
{
if (BIT(IntPend, i))
{
@@ -498,15 +497,14 @@ WRITE32_MEMBER(crystal_state::DMA_w)
{
if (((data ^ m_DMActrl[Which]) & (1 << 10)) && (data & (1 << 10))) //DMAOn
{
- uint32_t CTR = data;
- uint32_t SRC = space.read_dword(0x01800804 + Which * 0x10);
- uint32_t DST = space.read_dword(0x01800808 + Which * 0x10);
- uint32_t CNT = space.read_dword(0x0180080C + Which * 0x10);
- int i;
+ uint32_t const CTR = data;
+ uint32_t const SRC = space.read_dword(0x01800804 + Which * 0x10);
+ uint32_t const DST = space.read_dword(0x01800808 + Which * 0x10);
+ uint32_t const CNT = space.read_dword(0x0180080C + Which * 0x10);
if (CTR & 0x2) //32 bits
{
- for (i = 0; i < CNT; ++i)
+ for (int i = 0; i < CNT; ++i)
{
uint32_t v = space.read_dword(SRC + i * 4);
space.write_dword(DST + i * 4, v);
@@ -514,7 +512,7 @@ WRITE32_MEMBER(crystal_state::DMA_w)
}
else if (CTR & 0x1) //16 bits
{
- for (i = 0; i < CNT; ++i)
+ for (int i = 0; i < CNT; ++i)
{
uint16_t v = space.read_word(SRC + i * 2);
space.write_word(DST + i * 2, v);
@@ -522,7 +520,7 @@ WRITE32_MEMBER(crystal_state::DMA_w)
}
else //8 bits
{
- for (i = 0; i < CNT; ++i)
+ for (int i = 0; i < CNT; ++i)
{
uint8_t v = space.read_byte(SRC + i);
space.write_byte(DST + i, v);
@@ -543,7 +541,7 @@ READ32_MEMBER(crystal_state::crtc_r)
switch (offset)
{
case 0: // CRTC Status / Mode
- if ((m_crtcregs[0x30 / 4] & 1) == 0) // Interrace
+ if ((m_crtcregs[0x30 / 4] & 1) == 0) // Interlace
vdisp <<= 1;
if (m_screen->vpos() <= vdisp) // Vertical display enable status
@@ -637,12 +635,11 @@ void crystal_state::crtc_update()
// TODO : Implement other CRTC parameters
uint32_t hdisp = m_crtcregs[0x0c / 4] + 1;
uint32_t vdisp = m_crtcregs[0x1c / 4] + 1;
- if ((m_crtcregs[0x30 / 4] & 1) == 0) // Interrace
+ if ((m_crtcregs[0x30 / 4] & 1) == 0) // Interlace
vdisp <<= 1;
- rectangle visarea;
- visarea.set(0, hdisp - 1, 0, vdisp - 1);
- m_screen->configure(hdisp, vdisp, visarea, m_screen->frame_period().attoseconds() );
+ rectangle const visarea(0, hdisp - 1, 0, vdisp - 1);
+ m_screen->configure(hdisp, vdisp, visarea, m_screen->frame_period().attoseconds());
}
void crystal_state::internal_map(address_map &map)
@@ -1067,7 +1064,6 @@ uint32_t crystal_state::screen_update(screen_device &screen, bitmap_ind16 &bitma
uint16_t *Front, *Back;
uint16_t *Visible, *DrawDest;
uint16_t *srcline;
- int y;
uint16_t head, tail;
uint32_t width = cliprect.width();
@@ -1113,9 +1109,9 @@ uint32_t crystal_state::screen_update(screen_device &screen, bitmap_ind16 &bitma
SetVidReg(space, 0x8e, GetVidReg(space, 0x8e) ^ 1);
srcline = (uint16_t *) Visible;
- uint32_t dx = cliprect.left();
- for (y = cliprect.top(); y <= cliprect.bottom(); y++)
- std::copy_n( &srcline[(y * 1024) + dx], width, &bitmap.pix16(y, dx));
+ uint32_t const dx = cliprect.left();
+ for (int y = cliprect.top(); y <= cliprect.bottom(); y++)
+ std::copy_n(&srcline[(y * 1024) + dx], width, &bitmap.pix16(y, dx));
return 0;
}
diff --git a/src/mame/drivers/ddragon.cpp b/src/mame/drivers/ddragon.cpp
index b3ee1b13082..f4281f9a3b8 100644
--- a/src/mame/drivers/ddragon.cpp
+++ b/src/mame/drivers/ddragon.cpp
@@ -574,11 +574,6 @@ void ddragon_state::dd2_sub_map(address_map &map)
map(0xe000, 0xe000).w(FUNC(ddragon_state::ddragon2_sub_irq_w));
}
-void ddragon_state::ddragonba_sub_portmap(address_map &map)
-{
- map(0x0000, 0x01ff).w(FUNC(ddragon_state::ddragonba_port_w));
-}
-
/*************************************
*
@@ -1008,14 +1003,15 @@ MACHINE_CONFIG_START(ddragon_state::ddragonb)
MACHINE_CONFIG_END
-MACHINE_CONFIG_START(ddragon_state::ddragonba)
+void ddragon_state::ddragonba(machine_config &config)
+{
ddragon(config);
/* basic machine hardware */
- MCFG_DEVICE_REPLACE("sub", M6803, MAIN_CLOCK / 2) /* 6MHz / 4 internally */
- MCFG_DEVICE_PROGRAM_MAP(ddragonba_sub_map)
- MCFG_DEVICE_IO_MAP(ddragonba_sub_portmap)
-MACHINE_CONFIG_END
+ m6803_cpu_device &sub(M6803(config.replace(), "sub", MAIN_CLOCK / 2)); // 6MHz / 4 internally
+ sub.set_addrmap(AS_PROGRAM, &ddragon_state::ddragonba_sub_map);
+ sub.out_p2_cb().set(FUNC(ddragon_state::ddragonba_port_w));
+}
MACHINE_CONFIG_START(ddragon_state::ddragon6809)
diff --git a/src/mame/drivers/fcrash.cpp b/src/mame/drivers/fcrash.cpp
index ee13dc22be2..673c11806ef 100644
--- a/src/mame/drivers/fcrash.cpp
+++ b/src/mame/drivers/fcrash.cpp
@@ -280,7 +280,7 @@ WRITE16_MEMBER(cps_state::knightsb_layer_w)
WRITE16_MEMBER(cps_state::mtwinsb_layer_w)
{
m_cps_a_regs[0x06 / 2] = 0x9100; // bit of a hack - the game never writes this, but does need it
-
+
switch (offset)
{
case 0x00:
diff --git a/src/mame/drivers/hapyfish.cpp b/src/mame/drivers/hapyfish.cpp
index 118802a053e..5b52817cd5b 100644
--- a/src/mame/drivers/hapyfish.cpp
+++ b/src/mame/drivers/hapyfish.cpp
@@ -21,6 +21,8 @@
#include "screen.h"
#include "speaker.h"
+#include <algorithm>
+
#define VERBOSE_LEVEL ( 0 )
class hapyfish_state : public driver_device
@@ -34,7 +36,7 @@ public:
m_nand2(*this, "nand2"),
m_ldac(*this, "ldac"),
m_rdac(*this, "rdac")
- { }
+ { }
void hapyfish(machine_config &config);
@@ -70,10 +72,10 @@ inline void hapyfish_state::verboselog(int n_level, const char *s_fmt, ...)
{
va_list v;
char buf[32768];
- va_start( v, s_fmt);
- vsprintf( buf, s_fmt, v);
- va_end( v);
- logerror( "%s: %s", machine().describe_context(), buf);
+ va_start(v, s_fmt);
+ vsprintf(buf, s_fmt, v);
+ va_end(v);
+ logerror("%s: %s", machine().describe_context(), buf);
}
}
@@ -191,7 +193,7 @@ WRITE8_MEMBER(hapyfish_state::s3c2440_nand_data_w )
WRITE16_MEMBER(hapyfish_state::s3c2440_i2s_data_w )
{
- if ( offset )
+ if (offset)
m_ldac->write(data);
else
m_rdac->write(data);
@@ -217,7 +219,7 @@ void hapyfish_state::machine_start()
void hapyfish_state::machine_reset()
{
m_maincpu->reset();
- memset( m_port, 0, sizeof( m_port));
+ std::fill(std::begin(m_port), std::end(m_port), 0);
m_port[8] = 0x1800; // select NAND #1
}
diff --git a/src/mame/drivers/holeland.cpp b/src/mame/drivers/holeland.cpp
index 17ad2762bf2..8588707a67b 100644
--- a/src/mame/drivers/holeland.cpp
+++ b/src/mame/drivers/holeland.cpp
@@ -571,17 +571,17 @@ ROM_START( crzrallyrf )
ROM_LOAD( "crzrallyrf_8.1k", 0x4000, 0x2000, CRC(2a0d5bca) SHA1(8d7aedd63ea374a5809c24f957b0afa3cad437d0) )
ROM_LOAD( "crzrallyrf_9.1i", 0x6000, 0x2000, CRC(49c0c2b8) SHA1(30c4fe1dc2df499927f8fd4a041a707b81a04e1d) )
- /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
+ /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
ROM_REGION( 0x0300, "proms", 0 )
ROM_LOAD( "82s129.9n", 0x0000, 0x0100, CRC(98ff725a) SHA1(553f033212a7c4785c0beb8156400cabcd53cf25) ) /* Red component */
ROM_LOAD( "82s129.9m", 0x0100, 0x0100, CRC(d41f5800) SHA1(446046f5694357da876e1307f49584d79c8d9a1a) ) /* Green component */
ROM_LOAD( "82s129.9l", 0x0200, 0x0100, CRC(9ed49cb4) SHA1(f54e66e2211d5fb0da9a81e11670367ee4d9b49a) ) /* Blue component */
- /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
+ /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
ROM_REGION( 0x0200, "user1", 0 ) // unknown
ROM_LOAD( "82s147.1f", 0x0000, 0x0200, CRC(5261bc11) SHA1(1cc7a9a7376e65f4587b75ef9382049458656372) )
- /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
+ /* Not dumped on the Refreativos Franco PCB, taken from the parent set */
ROM_REGION( 0x0800, "plds", 0 )
ROM_LOAD( "pal16r6a.5k", 0x0000, 0x0104, CRC(3d12afba) SHA1(60245089947e4a4f7bfa94a8cc96d4d8eebe4afc) )
ROM_LOAD( "pal16r4a.5l", 0x0200, 0x0104, NO_DUMP ) /* PAL is read protected */
diff --git a/src/mame/drivers/hp9825.cpp b/src/mame/drivers/hp9825.cpp
index e61a49f7177..c7e83cc1ffe 100644
--- a/src/mame/drivers/hp9825.cpp
+++ b/src/mame/drivers/hp9825.cpp
@@ -215,7 +215,7 @@ void hp9825_state::cpu_mem_map(address_map &map)
READ16_MEMBER(hp9825_state::kb_scancode_r)
{
- // TODO:
+ // TODO:
uint8_t res = m_scancode;
if (m_shift_key->read()) {
BIT_SET(res , 7);
@@ -788,7 +788,7 @@ static INPUT_PORTS_START(hp9825)
PORT_BIT(IOP_MASK(27) , IP_ACTIVE_HIGH , IPT_UNUSED) // 5,11: N/U
PORT_BIT(IOP_MASK(28) , IP_ACTIVE_HIGH , IPT_UNUSED) // 5,12: N/U
PORT_BIT(IOP_MASK(29) , IP_ACTIVE_HIGH , IPT_UNUSED) // 5,13: N/U
- PORT_BIT(IOP_MASK(30) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_QUOTE) PORT_NAME("↑ √") // 5,14: ^
+ PORT_BIT(IOP_MASK(30) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_QUOTE) PORT_NAME(u8"\u2191 \u221A") // 5,14: ^ (↑ √)
PORT_BIT(IOP_MASK(31) , IP_ACTIVE_HIGH , IPT_UNUSED) // 5,15: N/U
PORT_START("KEY3")
@@ -819,9 +819,9 @@ static INPUT_PORTS_START(hp9825)
PORT_BIT(IOP_MASK(24) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_X) PORT_CHAR('x') PORT_CHAR('X') // 7,8: X
PORT_BIT(IOP_MASK(25) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_Y) PORT_CHAR('y') PORT_CHAR('Y') // 7,9: Y
PORT_BIT(IOP_MASK(26) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_Z) PORT_CHAR('z') PORT_CHAR('Z') // 7,10: Z
- PORT_BIT(IOP_MASK(27) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_NAME("π |") // 7,11: Pi
+ PORT_BIT(IOP_MASK(27) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_NAME(u8"π |") // 7,11: Pi
PORT_BIT(IOP_MASK(28) , IP_ACTIVE_HIGH , IPT_UNUSED) // 7,12: N/U
- PORT_BIT(IOP_MASK(29) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_END) PORT_NAME("→") // 7,13: Gazinta
+ PORT_BIT(IOP_MASK(29) , IP_ACTIVE_HIGH , IPT_KEYBOARD) PORT_CODE(KEYCODE_END) PORT_NAME(u8"\u2192") // 7,13: Gazinta (→)
PORT_BIT(IOP_MASK(30) , IP_ACTIVE_HIGH , IPT_UNUSED) // 7,14: N/U
PORT_BIT(IOP_MASK(31) , IP_ACTIVE_HIGH , IPT_UNUSED) // 7,15: N/U
diff --git a/src/mame/drivers/hp9k_3xx.cpp b/src/mame/drivers/hp9k_3xx.cpp
index 112287b8939..4c05ae2c237 100644
--- a/src/mame/drivers/hp9k_3xx.cpp
+++ b/src/mame/drivers/hp9k_3xx.cpp
@@ -241,7 +241,7 @@ TIMER_CALLBACK_MEMBER(hp9k3xx_state::bus_error_timeout)
WRITE16_MEMBER(hp9k3xx_state::led_w)
{
if (!(mem_mask & 0xff))
- return;
+ return;
LOG("LED: %02x\n", data & 0xff);
@@ -290,7 +290,7 @@ void hp9k3xx_state::set_bus_error(uint32_t address, bool write, uint16_t mem_mas
m_bus_error = true;
m_maincpu->set_buserror_details(address, write, m_maincpu->get_fc());
- m_maincpu->set_input_line(M68K_LINE_BUSERROR, ASSERT_LINE);
+ m_maincpu->set_input_line(M68K_LINE_BUSERROR, ASSERT_LINE);
m_bus_error_timer->adjust(m_maincpu->cycles_to_attotime(16)); // let rmw cycles complete
}
diff --git a/src/mame/drivers/ibm6580.cpp b/src/mame/drivers/ibm6580.cpp
index 98310683fbc..747218fc43e 100644
--- a/src/mame/drivers/ibm6580.cpp
+++ b/src/mame/drivers/ibm6580.cpp
@@ -926,7 +926,7 @@ MACHINE_CONFIG_START(ibm6580_state::ibm6580)
UPD765A(config, m_fdc, false, false);
m_fdc->intrq_wr_callback().set(FUNC(ibm6580_state::floppy_intrq));
-// m_fdc->intrq_wr_callback().append("pic8259", FUNC(pic8259_device::ir4_w));
+// m_fdc->intrq_wr_callback().append("pic8259", FUNC(pic8259_device::ir4_w));
m_fdc->drq_wr_callback().set(m_dma8257, FUNC(i8257_device::dreq0_w));
MCFG_FLOPPY_DRIVE_ADD(UPD765_TAG ":0", dw_floppies, "8sssd", floppy_image_device::default_floppy_formats)
MCFG_FLOPPY_DRIVE_ADD(UPD765_TAG ":1", dw_floppies, "8sssd", floppy_image_device::default_floppy_formats)
diff --git a/src/mame/drivers/itgamble.cpp b/src/mame/drivers/itgamble.cpp
index 9e23b0eb67d..3907948267f 100644
--- a/src/mame/drivers/itgamble.cpp
+++ b/src/mame/drivers/itgamble.cpp
@@ -19,7 +19,7 @@
There are at least 4 variants for this hardware.
The first 3 share the same layout, the latest is a complete redesign.
----------
+---------
The oldest revision (green) is marked "H83048" with the following hardware:
(note that @IC2 is unpopulated)
CPU:
@@ -27,7 +27,7 @@ The oldest revision (green) is marked "H83048" with the following hardware:
(128KB ROM; 4KB RAM)
Sound:
1x OKI 6295 or clones @IC24
- 1x LM358N dual operational amplifier @IC27
+ 1x LM358N dual operational amplifier @IC27
1x TDA2003 audio amplifier @IC26
PLDs:
1x ispLSI2064-80LJ @IC12
@@ -89,14 +89,14 @@ A complete redesign (green) is marked "ND 2001 Rev 1.0" and uses smaller factor
(128KB ROM; 4KB RAM)
Sound:
1x OKI 6295 or clones @IC15
- 1x LM358N dual operational amplifier @IC13
+ 1x LM358N dual operational amplifier @IC13
1x TDA2003 audio amplifier @IC8
PLDs:
1x ispLSI2064-80LJ @IC24
Clock:
1x Xtal 30.000 MHz @OSC1
1x Resonator ZTB1000J (1000 kHz) @X1
- 1x Xtal K0SoF @X2
+ 1x Xtal K0SoF @X2
ROMs:
1x 27C010 (sound) @IC1
2x 27C040 (graphics) @IC7,8
@@ -112,8 +112,8 @@ A complete redesign (green) is marked "ND 2001 Rev 1.0" and uses smaller factor
Known games on this hardware revision are:
2001.11 Bowling Road (Ver 1.4)
2001.12 World Cup (Ver 1.4)
-
-
+
+
*******************************************************************/
#include "emu.h"
@@ -476,7 +476,7 @@ ROM_END
/* Pin Ups (Ver 1.0 Rev A)
PCB is marked: "CE H83048" on component side
PCB is marked: "H83048 bottom" on solder side
-PCB is labeled: "PIN UPS VER.1.0 REV.A" on component side
+PCB is labeled: "PIN UPS VER.1.0 REV.A" on component side
*/
ROM_START( pinups )
ROM_REGION( 0x1000000, "maincpu", 0 )
diff --git a/src/mame/drivers/ltd.cpp b/src/mame/drivers/ltd.cpp
index 3d7f5976fea..3e4f83fbdcf 100644
--- a/src/mame/drivers/ltd.cpp
+++ b/src/mame/drivers/ltd.cpp
@@ -81,7 +81,6 @@ private:
DECLARE_WRITE8_MEMBER(count_reset_w);
TIMER_DEVICE_CALLBACK_MEMBER(timer_r);
void ltd3_map(address_map &map);
- void ltd4_io(address_map &map);
void ltd4_map(address_map &map);
bool m_timer_r;
@@ -123,12 +122,6 @@ void ltd_state::ltd4_map(address_map &map)
map(0xc000, 0xdfff).rom().mirror(0x2000).region("roms", 0);
}
-void ltd_state::ltd4_io(address_map &map)
-{
- map(0x0100, 0x0100).rw(FUNC(ltd_state::port1_r), FUNC(ltd_state::port1_w));
- map(0x0101, 0x0101).rw(FUNC(ltd_state::port2_r), FUNC(ltd_state::port2_w));
-}
-
// bits 6,7 not connected to data bus
// 1=does something in Atlantis; 2=does something in Black Hole; note that sometimes pressing G or H will reboot the machine.
static INPUT_PORTS_START( ltd3 )
@@ -548,9 +541,12 @@ MACHINE_CONFIG_END
MACHINE_CONFIG_START(ltd_state::ltd4)
/* basic machine hardware */
- MCFG_DEVICE_ADD("maincpu", M6803, XTAL(3'579'545)) // guess, no details available
- MCFG_DEVICE_PROGRAM_MAP(ltd4_map)
- MCFG_DEVICE_IO_MAP(ltd4_io)
+ m6803_cpu_device &maincpu(M6803(config, "maincpu", XTAL(3'579'545))); // guess, no details available
+ maincpu.set_addrmap(AS_PROGRAM, &ltd_state::ltd4_map);
+ maincpu.in_p1_cb().set(FUNC(ltd_state::port1_r));
+ maincpu.out_p1_cb().set(FUNC(ltd_state::port1_w));
+ maincpu.in_p2_cb().set(FUNC(ltd_state::port2_r));
+ maincpu.out_p2_cb().set(FUNC(ltd_state::port2_w));
NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0);
diff --git a/src/mame/drivers/mpu4misc.cpp b/src/mame/drivers/mpu4misc.cpp
index 8012bb37952..7a510a6d644 100644
--- a/src/mame/drivers/mpu4misc.cpp
+++ b/src/mame/drivers/mpu4misc.cpp
@@ -265,7 +265,7 @@ GAME_CUSTOM( 199?, m4rhrock__a, m4rhrock, "rhr_v300_1216_ce52_nlv.bin", 0x0
ROM_REGION( 0x200000, "msm6376", ROMREGION_ERASE00 ) \
ROM_LOAD( "redhotwheelssnd.p1", 0x0000, 0x080000, CRC(7b274a71) SHA1(38ba69084819133253b41f2eb1d784104e5f10f7) ) \
ROM_LOAD( "redhotwheelssnd.p2", 0x0000, 0x080000, CRC(e36e19e2) SHA1(204554622c9020479b095acd4fbab1f21f829137) )
-
+
#undef GAME_CUSTOM
#define GAME_CUSTOM(year, setname,parent,name,offset,length,hash,company,title) \
ROM_START( setname ) \
@@ -325,11 +325,11 @@ GAME_CUSTOM( 199?, m4shoknr__a, m4shoknr, "snr_v300_1221_c8ff_nlv.bin", 0
GAME_CUSTOM( 199?, m4shoknr__b, m4shoknr, "snr_v200_1145_047f_lv.bin", 0x0000, 0x040000, CRC(73ef1e1a) SHA1(6ccaf64daa5acacfba4df576281bb5478f2fbd29), "Qps","Shock 'n' Roll (Qps) (MPU4) (set 3)" )
GAME_CUSTOM( 199?, m4shoknr__c, m4shoknr, "snr_v200_1655_5a69_nlv.bin", 0x0000, 0x040000, CRC(50ba0c6b) SHA1(767fd59858fc55ae95f096f00c54bd619369a56c), "Qps","Shock 'n' Roll (Qps) (MPU4) (set 4)" )
-// 71000300.lo.hex and 71000300.hi.hex converted
+// 71000300.lo.hex and 71000300.hi.hex converted
#define M4TORNAD_EXTRA_ROMS \
ROM_REGION( 0x200000, "msm6376", ROMREGION_ERASE00 ) \
ROM_LOAD( "tornadosnd.p1", 0x000000, 0x080000, CRC(cac88f25) SHA1(6ccbf372d983a47a49caedb8a526fc7703b31ed4) ) \
- ROM_LOAD( "tornadosnd.p2", 0x080000, 0x080000, CRC(ef4f563d) SHA1(1268061edd93474296e3454e0a2e706b90c0621c) )
+ ROM_LOAD( "tornadosnd.p2", 0x080000, 0x080000, CRC(ef4f563d) SHA1(1268061edd93474296e3454e0a2e706b90c0621c) )
#undef GAME_CUSTOM
#define GAME_CUSTOM(year, setname,parent,name,offset,length,hash,company,title) \
@@ -353,7 +353,7 @@ GAME_CUSTOM( 199?, m4tornad__g, m4tornad, "tornsp_v200_1626_ec93_lv.bin",
#define M4SHKWAV_EXTRA_ROMS \
ROM_REGION( 0x200000, "msm6376", ROMREGION_ERASE00 ) \
ROM_LOAD( "shocksnd.p1", 0x000000, 0x080000, CRC(54bf0ddb) SHA1(693b855367972b5a45e9d2d6152849ab2cde38a7) ) \
- ROM_LOAD( "shocksnd.p2", 0x080000, 0x080000, CRC(facebc55) SHA1(75367473646cfc735f4d1267e13a9c92ea19c4e3) )
+ ROM_LOAD( "shocksnd.p2", 0x080000, 0x080000, CRC(facebc55) SHA1(75367473646cfc735f4d1267e13a9c92ea19c4e3) )
#undef GAME_CUSTOM
#define GAME_CUSTOM(year, setname,parent,name,offset,length,hash,company,title) \
diff --git a/src/mame/drivers/mwarr.cpp b/src/mame/drivers/mwarr.cpp
index 7cacdddc10a..1b9e1093ddc 100644
--- a/src/mame/drivers/mwarr.cpp
+++ b/src/mame/drivers/mwarr.cpp
@@ -271,7 +271,7 @@ GFXDECODE_END
* Video emulation
*
*************************************/
-
+
uint32_t mwarr_state::screen_update_mwarr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
return m_video->draw(screen, bitmap, cliprect);
diff --git a/src/mame/drivers/namcond1.cpp b/src/mame/drivers/namcond1.cpp
index 4c55d5e3f25..fd1ecf280e5 100644
--- a/src/mame/drivers/namcond1.cpp
+++ b/src/mame/drivers/namcond1.cpp
@@ -13,11 +13,11 @@
- GFX rom banking is a mystery (bad ROMs? Encryption?)
- Where is the extra data ROM mapped?
- gynotai TODOs:
- - printer (disable it in service mode);
- - ball sensors aren't understood;
- - Seems to dislike our YGV608 row/colscroll handling;
-
+ gynotai TODOs:
+ - printer (disable it in service mode);
+ - ball sensors aren't understood;
+ - Seems to dislike our YGV608 row/colscroll handling;
+
To make abcheck run when the EEPROM is clear:
- F2 to enter service mode
- Player 3 A/B to navigate to GAME OPTIONS
@@ -522,7 +522,7 @@ ROM_START( gynotai )
ROM_REGION( 0x800000, "ygv608", 0 ) /* 8MB character generator */
ROM_LOAD( "gy1cg0.10e", 0x000000, 0x400000, CRC(938c7912) SHA1(36278a945a00e1549ae55ec65a9b4001537023b0) )
- ROM_LOAD( "gy1cg1.10f", 0x400000, 0x400000, CRC(5a518733) SHA1(b6ea91629bc6ddf67c47c4189084aa947f4e31ed) )
+ ROM_LOAD( "gy1cg1.10f", 0x400000, 0x400000, CRC(5a518733) SHA1(b6ea91629bc6ddf67c47c4189084aa947f4e31ed) )
ROM_REGION( 0x200000, "c352", 0 ) // Samples
ROM_LOAD( "gy1voic.7c", 0x000000, 0x200000, CRC(f135e79b) SHA1(01ce3e3b366d0b9045ad8599b60ca33c6d21f150) )
@@ -539,9 +539,9 @@ ROM_START( abcheck )
ROM_REGION( 0x800000, "ygv608", 0 ) /* 4MB character generator */
// TODO: gynotai proves these might be underdumped, please check.
ROM_LOAD( "an1cg0.10e", 0x000000, 0x200000, BAD_DUMP CRC(6dae0531) SHA1(2f4a4a22d461eb9a5bb88bdfccc3aff44cd3faee) )
- ROM_RELOAD( 0x200000, 0x200000 )
+ ROM_RELOAD( 0x200000, 0x200000 )
ROM_LOAD( "an1cg1.10f", 0x400000, 0x200000, BAD_DUMP CRC(8485607a) SHA1(1b9a1950c6db61a2b546fe2f5e56333593e93fb4) )
- ROM_RELOAD( 0x600000, 0x200000 )
+ ROM_RELOAD( 0x600000, 0x200000 )
ROM_REGION( 0x1000000, "c352", 0 ) // Samples
ROM_LOAD( "an1voice.7c", 0x000000, 0x200000, CRC(d2bfa453) SHA1(6b7d6bb4d65290d8fd3df5d12b41ae7dce5f3f1c) )
diff --git a/src/mame/drivers/namcos22.cpp b/src/mame/drivers/namcos22.cpp
index f6cfd1c85a4..319cff0948a 100644
--- a/src/mame/drivers/namcos22.cpp
+++ b/src/mame/drivers/namcos22.cpp
@@ -17,6 +17,7 @@
* - C139 for linked cabinets, as well as in RR fullscale
* - confirm DSP and MCU clocks and their IRQ timing
* - EEPROM write timing should be around 5ms, it doesn't do any data/rdy polling
+ * - where is the steering wheel motor torque output for dirtdash?
* - texture u/v mapping is often 1 pixel off, resulting in many glitch lines/gaps between textures. The glitch may be in MAME core:
* it used to be much worse with the legacy_poly_manager
* - find out how/where vics num_sprites is determined exactly, currently a workaround is needed for airco22b and dirtdash
@@ -32,6 +33,8 @@
* - PDP command 0xfff9, used in alpinr2b to modify titlescreen logo animation in pointram (should show a snowmelting effect)
* - support for text layer video partial updates after posirq, alpinesa does raster effects on it
* - alpha blended sprite/poly with priority over alpha blended text doesn't work right (see dirtdash countdown when you start at jungle level)
+ * - ss22 poly translucency is probably more limited than currently emulated, not supporting stacked layers
+ * - there's a sprite limit per scanline, eg. timecris submarine explosion smoke partially erases sprites on real hardware
* - cybrcomm arrows(black part) should be below textlayer when a messagebox pops up
* - cybrcycc speed dial needle is missing
* - global offset is wrong in non-super22 servicemode video test, and above that, it flickers in acedrvrw, victlapw
@@ -2733,38 +2736,97 @@ void namcos22_state::iomcu_s22_io(address_map &map)
// System Super22 M37710
-TIMER_DEVICE_CALLBACK_MEMBER(namcos22_state::mcu_irq)
+/*
+ SS22 MCU outputs
+ ----------------
+ sent to mcuoutx where x = 0 to 15
+ mcuout0 = coincounter
+
+ Air Combat 22:
+ 1 = start button lamp
+
+ Alpine Racer 1,2, Alpine Surfer:
+ 1 = steplock motor lock
+ 2 = steplock motor on
+ 4 = start button lamp
+ 5 = left button lamp
+ 6 = right button lamp
+
+ Aqua Jet:
+ 1 = ?
+ 2 = fan motor
+ 4 = start button lamp
+ 7 = air spring
+
+ Armadillo Racing:
+ 4 = start button lamp
+
+ Cyber Cycles:
+ 1 = 1 lamp
+ 2 = 2 lamp
+ 3 = 3 lamp
+ 4 = 4 lamp
+ 5 = red lamp
+ 6 = yellow lamp
+ 7 = blue lamp
+ 8 = green lamp
+ 9 = start button lamp
+
+ Dirt Dash:
+ 1 = steering wheel motor on
+ 4 = front left valve
+ 5 = front right valve
+ 6 = rear left valve
+ 7 = rear right valve
+ where is steering wheel torque?
+
+ Prop Cycle:
+ 1 = fan motor
+ 2 = start button lamp
+
+ Time Crisis:
+ 1 = gun solenoid
+
+ Tokyo Wars:
+ 1 = start button lamp
+ other: ?
+*/
+
+WRITE8_MEMBER(namcos22_state::mcu_port4_w)
{
- int scanline = param;
+ // d3: input port select for port 5
+ // d4: port 5 direction?
+ // d5,d6: output strobe for port 5
- /* TODO: real sources of these */
- if (scanline == 480)
- m_mcu->set_input_line(M37710_LINE_IRQ0, HOLD_LINE);
- else if (scanline == 0)
- m_mcu->set_input_line(M37710_LINE_ADC, HOLD_LINE);
- else if (scanline == 240)
- m_mcu->set_input_line(M37710_LINE_IRQ2, HOLD_LINE);
-}
+ if (~m_mcu_iocontrol & data & 0x20)
+ {
+ for (int i = 0; i < 8; i++)
+ m_mcuout[i] = BIT(m_mcu_outdata, i);
+ machine().bookkeeping().coin_counter_w(0, m_mcu_outdata & 1);
+ }
+ if (~m_mcu_iocontrol & data & 0x40)
+ {
+ for (int i = 0; i < 8; i++)
+ m_mcuout[8+i] = BIT(m_mcu_outdata, i);
+ }
-WRITE8_MEMBER(namcos22_state::mcu_port4_w)
-{
- m_p4 = data;
+ m_mcu_iocontrol = data;
}
READ8_MEMBER(namcos22_state::mcu_port4_r)
{
- return m_p4;
+ return m_mcu_iocontrol;
}
WRITE8_MEMBER(namcos22_state::mcu_port5_w)
{
- ;
+ m_mcu_outdata = data;
}
READ8_MEMBER(namcos22_state::mcu_port5_r)
{
- if (m_p4 & 8)
+ if (m_mcu_iocontrol & 8)
return m_mcup5a.read_safe(0xff);
else
return m_mcup5b.read_safe(0xff);
@@ -2772,21 +2834,12 @@ READ8_MEMBER(namcos22_state::mcu_port5_r)
WRITE8_MEMBER(namcos22_state::mcu_port6_w)
{
- ;
+ // always 2?
}
READ8_MEMBER(namcos22_state::mcu_port6_r)
{
- return 0;
-}
-
-WRITE8_MEMBER(namcos22_state::mcu_port7_w)
-{
- ;
-}
-
-READ8_MEMBER(namcos22_state::mcu_port7_r)
-{
+ // discarded
return 0;
}
@@ -2812,10 +2865,22 @@ void namcos22_state::mcu_io(address_map &map)
map(M37710_PORT4, M37710_PORT4).rw(FUNC(namcos22_state::mcu_port4_r), FUNC(namcos22_state::mcu_port4_w));
map(M37710_PORT5, M37710_PORT5).rw(FUNC(namcos22_state::mcu_port5_r), FUNC(namcos22_state::mcu_port5_w));
map(M37710_PORT6, M37710_PORT6).rw(FUNC(namcos22_state::mcu_port6_r), FUNC(namcos22_state::mcu_port6_w));
- map(M37710_PORT7, M37710_PORT7).rw(FUNC(namcos22_state::mcu_port7_r), FUNC(namcos22_state::mcu_port7_w));
map(M37710_ADC0_L, M37710_ADC7_H).r(FUNC(namcos22_state::namcos22s_mcu_adc_r));
}
+TIMER_DEVICE_CALLBACK_MEMBER(namcos22_state::mcu_irq)
+{
+ int scanline = param;
+
+ /* TODO: real sources of these */
+ if (scanline == 480)
+ m_mcu->set_input_line(M37710_LINE_IRQ0, HOLD_LINE);
+ else if (scanline == 0)
+ m_mcu->set_input_line(M37710_LINE_ADC, HOLD_LINE);
+ else if (scanline == 240)
+ m_mcu->set_input_line(M37710_LINE_IRQ2, HOLD_LINE);
+}
+
/*********************************************************************************************/
// custom input handling
@@ -2919,53 +2984,43 @@ TIMER_DEVICE_CALLBACK_MEMBER(namcos22_state::alpine_steplock_callback)
m_motor_status = param;
}
-WRITE8_MEMBER(namcos22_state::alpine_mcu_port5_w)
+WRITE8_MEMBER(namcos22_state::alpine_mcu_port4_w)
{
- // bits 1+2 are steplock motor outputs
- if ((data & 6) == 6)
+ if (~m_mcu_iocontrol & data & 0x20)
{
- if (m_motor_status == 2)
+ // bits 1+2 are steplock motor outputs
+ if ((m_mcu_outdata & 6) == 6)
{
- // free steps
- m_motor_status = 0;
- m_motor_timer->adjust(attotime::from_msec(500), 1);
+ if (m_motor_status == 2)
+ {
+ // free steps
+ m_motor_status = 0;
+ m_motor_timer->adjust(attotime::from_msec(500), 1);
+ }
}
- }
- else if (data & 4)
- {
- if (m_motor_status == 1)
+ else if (m_mcu_outdata & 4)
{
- // lock steps
- m_motor_status = 0;
- m_motor_timer->adjust(attotime::from_msec(500), 2);
+ if (m_motor_status == 1)
+ {
+ // lock steps
+ m_motor_status = 0;
+ m_motor_timer->adjust(attotime::from_msec(500), 2);
+ }
}
}
+
+ mcu_port4_w(space, offset, data);
}
void namcos22_state::alpine_io_map(address_map &map)
{
mcu_io(map);
- map(M37710_PORT5, M37710_PORT5).w(FUNC(namcos22_state::alpine_mcu_port5_w));
+ map(M37710_PORT4, M37710_PORT4).w(FUNC(namcos22_state::alpine_mcu_port4_w));
}
// Prop Cycle
-WRITE8_MEMBER(namcos22_state::propcycle_mcu_port5_w)
-{
- // prop cycle outputs:
- // bit 1 = fan
- // bit 2 = button light
- output().set_value("fan0", data & 1);
- m_led = BIT(data, 1);
-}
-
-void namcos22_state::propcycl_io_map(address_map &map)
-{
- mcu_io(map);
- map(M37710_PORT5, M37710_PORT5).w(FUNC(namcos22_state::propcycle_mcu_port5_w));
-}
-
TIMER_DEVICE_CALLBACK_MEMBER(namcos22_state::propcycl_pedal_interrupt)
{
m_mcu->pulse_input_line(M37710_LINE_TIMERA3TICK, m_mcu->minimum_quantum_time());
@@ -3553,7 +3608,7 @@ static INPUT_PORTS_START( adillor )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_START("MCUP5B")
- PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_BUTTON1 )
+ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
PORT_START("TRACKX")
@@ -3723,7 +3778,7 @@ ALLOW_SAVE_TYPE(namcos22_dsp_upload_state);
void namcos22_state::machine_start()
{
- m_led.resolve();
+ m_mcuout.resolve();
m_cpuled.resolve();
m_portbits[0] = 0xffff;
m_portbits[1] = 0xffff;
@@ -3731,7 +3786,7 @@ void namcos22_state::machine_start()
m_keycus_rng = 0;
m_su_82 = 0;
m_irq_state = 0;
- m_p4 = 0;
+ m_mcu_iocontrol = 0;
m_old_coin_state = 0;
m_credits1 = m_credits2 = 0;
@@ -3771,7 +3826,8 @@ void namcos22_state::machine_start()
save_item(NAME(m_UploadDestIdx));
save_item(NAME(m_alpinesa_protection));
save_item(NAME(m_motor_status));
- save_item(NAME(m_p4));
+ save_item(NAME(m_mcu_iocontrol));
+ save_item(NAME(m_mcu_outdata));
save_item(NAME(m_su_82));
save_item(NAME(m_keycus_id));
save_item(NAME(m_keycus_rng));
@@ -3897,7 +3953,7 @@ MACHINE_CONFIG_START(namcos22_state::namcos22s)
MCFG_DEVICE_PROGRAM_MAP(mcu_program)
MCFG_DEVICE_IO_MAP(mcu_io)
MCFG_TIMER_DRIVER_ADD_SCANLINE("mcu_irq", namcos22_state, mcu_irq, "screen", 0, 240)
- MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // erratic inputs otherwise, probably mcu vs maincpu shareram
+ MCFG_QUANTUM_TIME(attotime::from_hz(9000)) // erratic inputs otherwise, probably mcu vs maincpu shareram
MCFG_DEVICE_REMOVE("iomcu")
@@ -3972,9 +4028,6 @@ MACHINE_CONFIG_END
MACHINE_CONFIG_START(namcos22_state::propcycl)
namcos22s(config);
- MCFG_DEVICE_MODIFY("mcu")
- MCFG_DEVICE_IO_MAP(propcycl_io_map)
-
MCFG_TIMER_DRIVER_ADD_PERIODIC("pc_p_upd", namcos22_state, propcycl_pedal_update, attotime::from_msec(20))
MCFG_TIMER_DRIVER_ADD("pc_p_int", namcos22_state, propcycl_pedal_interrupt)
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/namcos23.cpp b/src/mame/drivers/namcos23.cpp
index 46e6ecf4d5d..70e9d064521 100644
--- a/src/mame/drivers/namcos23.cpp
+++ b/src/mame/drivers/namcos23.cpp
@@ -1599,7 +1599,7 @@ private:
const uint32_t *m_ptrom;
uint32_t m_ptrom_limit;
uint8_t m_mcu_unk;
-
+
int m_vblank_count;
// It may only be 128
@@ -2902,9 +2902,9 @@ READ16_MEMBER(namcos23_state::sub_comm_r)
// PC=0xbfc03838 bit 7 high => fail (data loaded must be parsed somehow)
return 1 | 2;
}
-
+
m_maincpu->set_input_line(MIPS3_IRQ4, CLEAR_LINE);
- // data rx, TBD
+ // data rx, TBD
return m_mcu_unk; //machine().rand();
}
diff --git a/src/mame/drivers/pacman.cpp b/src/mame/drivers/pacman.cpp
index 79b71f42aba..44cb77c265c 100644
--- a/src/mame/drivers/pacman.cpp
+++ b/src/mame/drivers/pacman.cpp
@@ -4197,24 +4197,24 @@ ROM_START( mspacmanbg )
ROM_END
ROM_START( mspacmanbg2 )
- ROM_REGION( 0x10000, "maincpu", 0 )
- ROM_LOAD( "11-prg.bin", 0x0000, 0x4000, CRC(e11d4132) SHA1(9ab6b9e1ec8ad183ccdddb971e8be3eb3f59db01) )
- ROM_CONTINUE(0x8000,0x4000) // blocks 5+6 are repeated twice in here
-
- ROM_REGION( 0x8000, "gfx1", 0 )
- ROM_LOAD( "13-chr.bin", 0x0000, 0x0800, CRC(8ee4a3b0) SHA1(01e3453c99f7a5d78ab083c49c650e898c0dd2ee) )
- ROM_CONTINUE(0x1000,0x800)
- ROM_CONTINUE(0x0800,0x800)
- ROM_CONTINUE(0x1800,0x800)
- ROM_IGNORE(0x2000)
-
- ROM_REGION( 0x0120, "proms", 0 ) // not dumped for this set
- ROM_LOAD( "82s123.h7", 0x0000, 0x0020, BAD_DUMP CRC(3545e7e9) SHA1(b866b02579438afb11296e5c53a32c6425bd044d) )
- ROM_LOAD( "82s129-3.d1", 0x0020, 0x0100, BAD_DUMP CRC(3eb3a8e4) SHA1(19097b5f60d1030f8b82d9f1d3a241f93e5c75d6) )
-
- ROM_REGION( 0x0200, "namco", 0 ) /* sound PROMs, not dumped for this set */
- ROM_LOAD( "82s129-1.a9", 0x0000, 0x0100, BAD_DUMP CRC(a9cc86bf) SHA1(bbcec0570aeceb582ff8238a4bc8546a23430081) )
- ROM_LOAD( "82s129-2.c9", 0x0100, 0x0100, BAD_DUMP CRC(77245b66) SHA1(0c4d0bee858b97632411c440bea6948a74759746) )
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "11-prg.bin", 0x0000, 0x4000, CRC(e11d4132) SHA1(9ab6b9e1ec8ad183ccdddb971e8be3eb3f59db01) )
+ ROM_CONTINUE(0x8000,0x4000) // blocks 5+6 are repeated twice in here
+
+ ROM_REGION( 0x8000, "gfx1", 0 )
+ ROM_LOAD( "13-chr.bin", 0x0000, 0x0800, CRC(8ee4a3b0) SHA1(01e3453c99f7a5d78ab083c49c650e898c0dd2ee) )
+ ROM_CONTINUE(0x1000,0x800)
+ ROM_CONTINUE(0x0800,0x800)
+ ROM_CONTINUE(0x1800,0x800)
+ ROM_IGNORE(0x2000)
+
+ ROM_REGION( 0x0120, "proms", 0 ) // not dumped for this set
+ ROM_LOAD( "82s123.h7", 0x0000, 0x0020, BAD_DUMP CRC(3545e7e9) SHA1(b866b02579438afb11296e5c53a32c6425bd044d) )
+ ROM_LOAD( "82s129-3.d1", 0x0020, 0x0100, BAD_DUMP CRC(3eb3a8e4) SHA1(19097b5f60d1030f8b82d9f1d3a241f93e5c75d6) )
+
+ ROM_REGION( 0x0200, "namco", 0 ) /* sound PROMs, not dumped for this set */
+ ROM_LOAD( "82s129-1.a9", 0x0000, 0x0100, BAD_DUMP CRC(a9cc86bf) SHA1(bbcec0570aeceb582ff8238a4bc8546a23430081) )
+ ROM_LOAD( "82s129-2.c9", 0x0100, 0x0100, BAD_DUMP CRC(77245b66) SHA1(0c4d0bee858b97632411c440bea6948a74759746) )
ROM_END
ROM_START( mspacmanbgd )
@@ -4970,7 +4970,7 @@ ROM_START( titanpac ) /* GDP-01 main PCB with GDP-02 auxiliary card (same as Pir
ROM_LOAD( "82s126.3m", 0x0100, 0x0100, CRC(77245b66) SHA1(0c4d0bee858b97632411c440bea6948a74759746) ) /* timing - not used */
ROM_END
-/* Bootleg from Spanish company "FAMARE S.A.". Board labeled "FAMARESA 560-002"
+/* Bootleg from Spanish company "FAMARE S.A.". Board labeled "FAMARESA 560-002"
It's mainly a hack to remove Namco logo, but it was on an original Famaresa bootleg hardware */
ROM_START( pacmanfm )
ROM_REGION( 0x10000, "maincpu", 0 )
@@ -5299,17 +5299,17 @@ ROM_START( mspacmbmc )
ROM_LOAD( "misspacmanfalgas_4.bin", 0x8000, 0x1000, CRC(8c3e6de6) SHA1(fed6e9a2b210b07e7189a18574f6b8c4ec5bb49b) )
ROM_LOAD( "misspacmanfalgas_5.bin", 0x9000, 0x1000, CRC(206a9623) SHA1(20006f945c1b7b0e3c0415eecc0b148e5a6a1dfa) )
- /* Undumped on the Marti Colls PCB, taken from the parent set */
+ /* Undumped on the Marti Colls PCB, taken from the parent set */
ROM_REGION( 0x2000, "gfx1", 0 )
ROM_LOAD( "5e", 0x0000, 0x1000, BAD_DUMP CRC(5c281d01) SHA1(5e8b472b615f12efca3fe792410c23619f067845) )
ROM_LOAD( "5f", 0x1000, 0x1000, BAD_DUMP CRC(615af909) SHA1(fd6a1dde780b39aea76bf1c4befa5882573c2ef4) )
- /* Undumped on the Marti Colls PCB, taken from the parent set */
+ /* Undumped on the Marti Colls PCB, taken from the parent set */
ROM_REGION( 0x0120, "proms", 0 )
ROM_LOAD( "82s123.7f", 0x0000, 0x0020, BAD_DUMP CRC(2fc650bd) SHA1(8d0268dee78e47c712202b0ec4f1f51109b1f2a5) )
ROM_LOAD( "82s126.4a", 0x0020, 0x0100, BAD_DUMP CRC(3eb3a8e4) SHA1(19097b5f60d1030f8b82d9f1d3a241f93e5c75d6) )
- /* Undumped on the Marti Colls PCB, taken from the parent set */
+ /* Undumped on the Marti Colls PCB, taken from the parent set */
ROM_REGION( 0x0200, "namco", 0 ) /* sound PROMs */
ROM_LOAD( "82s126.1m", 0x0000, 0x0100, BAD_DUMP CRC(a9cc86bf) SHA1(bbcec0570aeceb582ff8238a4bc8546a23430081) )
ROM_LOAD( "82s126.3m", 0x0100, 0x0100, BAD_DUMP CRC(77245b66) SHA1(0c4d0bee858b97632411c440bea6948a74759746) ) /* timing - not used */
diff --git a/src/mame/drivers/peplus.cpp b/src/mame/drivers/peplus.cpp
index 167bd15f6e0..de73bf1a0b2 100644
--- a/src/mame/drivers/peplus.cpp
+++ b/src/mame/drivers/peplus.cpp
@@ -1480,7 +1480,7 @@ ROM_END
ROM_START( peset004 ) /* Normal board : Set Chip (Set004) - PE+ Set Denomination / Enable Validator */
ROM_REGION( 0x10000, "maincpu", 0 )
- ROM_LOAD( "set004.u68", 0x00000, 0x10000, CRC(b5729571) SHA1(fa3bb1fec81692a898213f9521ac0b2a4d1a8968) )
+ ROM_LOAD( "set004.u68", 0x00000, 0x10000, CRC(b5729571) SHA1(fa3bb1fec81692a898213f9521ac0b2a4d1a8968) ) /* 09/17/93 @ IGT L93-1722 */
ROM_REGION( 0x020000, "gfx1", 0 )
ROM_LOAD( "mro-cg740.u72", 0x00000, 0x8000, CRC(72667f6c) SHA1(89843f472cc0329317cfc643c63bdfd11234b194) ) /* 08/12/87 @ IGT L87-2243 */
@@ -1520,7 +1520,19 @@ ROM_START( peset022 ) /* Normal board : Set Chip (Set022) - PE+ Set Denomination
ROM_LOAD( "cap740.u50", 0x0000, 0x0100, CRC(6fe619c4) SHA1(49e43dafd010ce0fe9b2a63b96a4ddedcb933c6d) )
ROM_END
-/* Known to exsist SET033 - PE+ Set Denomination / Enable Validator / SAS 4.0 */
+ROM_START( peset033 ) /* Normal board : Set Chip (Set033) - PE+ Set Denomination / Enable Validator / SAS 4.0 */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "set033.u68", 0x00000, 0x10000, CRC(de9a5cc8) SHA1(7fab3334f212d9db78e9e348790dfaa0c9c5ec66) ) /* 02/04/97 @ IGT NV */
+
+ ROM_REGION( 0x020000, "gfx1", 0 )
+ ROM_LOAD( "mro-cg740.u72", 0x00000, 0x8000, CRC(72667f6c) SHA1(89843f472cc0329317cfc643c63bdfd11234b194) ) /* 08/12/87 @ IGT L87-2243 */
+ ROM_LOAD( "mgo-cg740.u73", 0x08000, 0x8000, CRC(7437254a) SHA1(bba166dece8af58da217796f81117d0b05752b87) )
+ ROM_LOAD( "mbo-cg740.u74", 0x10000, 0x8000, CRC(92e8c33e) SHA1(05344664d6fdd3f4205c50fa4ca76fc46c18cf8f) )
+ ROM_LOAD( "mxo-cg740.u75", 0x18000, 0x8000, CRC(ce4cbe0b) SHA1(4bafcd68be94a5deaae9661584fa0fc940b834bb) )
+
+ ROM_REGION( 0x100, "proms", 0 )
+ ROM_LOAD( "cap740.u50", 0x0000, 0x0100, CRC(6fe619c4) SHA1(49e43dafd010ce0fe9b2a63b96a4ddedcb933c6d) )
+ROM_END
ROM_START( peset038 ) /* Normal board : Set Chip (Set038) - PE+ Set Denomination / Enable Validator */
ROM_REGION( 0x10000, "maincpu", 0 )
@@ -14262,6 +14274,7 @@ GAMEL( 1987, peset001, 0, peplus, peplus_schip, peplus_state, init_pepl
GAMEL( 1987, peset004, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET004) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
GAMEL( 1987, peset012, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET012) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
GAMEL( 1987, peset022, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET022) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
+GAMEL( 1987, peset033, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET033) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
GAMEL( 1987, peset038, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET038) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
GAMEL( 1987, peset100, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET100) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
GAMEL( 1987, peset117, 0, peplus, peplus_schip, peplus_state, init_peplus, ROT0, "IGT - International Game Technology", "Player's Edge Plus (SET117) Set Chip", MACHINE_SUPPORTS_SAVE, layout_pe_schip )
diff --git a/src/mame/drivers/phoenix.cpp b/src/mame/drivers/phoenix.cpp
index 4cd06659071..80905f99ec7 100644
--- a/src/mame/drivers/phoenix.cpp
+++ b/src/mame/drivers/phoenix.cpp
@@ -437,7 +437,6 @@ GFXDECODE_END
MACHINE_RESET_MEMBER(phoenix_state,phoenix)
{
- membank("bank1")->set_base(memregion("maincpu")->base() + 0x4000);
}
diff --git a/src/mame/drivers/r9751.cpp b/src/mame/drivers/r9751.cpp
index eca4d9004ac..6ad473ad72d 100644
--- a/src/mame/drivers/r9751.cpp
+++ b/src/mame/drivers/r9751.cpp
@@ -113,7 +113,7 @@ private:
DECLARE_WRITE32_MEMBER(r9751_mmio_fff8_w);
DECLARE_READ8_MEMBER(pdc_dma_r);
- DECLARE_WRITE8_MEMBER(pdc_dma_w);
+ DECLARE_WRITE8_MEMBER(pdc_dma_w);
DECLARE_READ8_MEMBER(smioc_dma_r);
DECLARE_WRITE8_MEMBER(smioc_dma_w);
@@ -170,7 +170,7 @@ private:
#if ENABLE_TRACE_ALL_DEVICES
// Device tracing
-static const char * DeviceNames[] = {
+static char const *const DeviceNames[] = {
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,"??", // 0x00-0x07
"??","HDD",nullptr,nullptr,nullptr,nullptr,nullptr,nullptr, // 0x08-0x0F
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr, // 0x10-0x17
@@ -180,6 +180,7 @@ static const char * DeviceNames[] = {
"??",nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr, // 0x30-0x37
"SMIOCc?",nullptr,"SMIOCd?",nullptr,nullptr,nullptr,nullptr,"??" // 0x38-0x3F
};
+
struct GenericCommandRecord {
u32 AddressPattern;
const char * Name;
@@ -192,7 +193,7 @@ static const GenericCommandRecord GenericCommands[] = {
{ 0x2800, "DMA Busy" },
{ 0x3000, "Command Result" },
{ 0x4000, "Command" }, // Also a write length.
- //{ 0x8000, "various" }, // Read address,
+ //{ 0x8000, "various" }, // Read address,
//{ 0xC000, "various" }, // Write address, Read length
};
@@ -267,7 +268,7 @@ void r9751_state::trace_device(int address, int data, const char* direction)
// Device is not enabled for tracing.
return;
}
-
+
if ((address == m_trace_last_address[dev]) && (data == m_trace_last_data[dev]) && (direction == m_trace_last_direction[dev]))
{
m_trace_repeat_count[dev]++;
@@ -392,8 +393,8 @@ static const SystemRegisterInfo SystemRegisters[] = {
};
-static const int MaxSystemTables = 256; // FF00xxxx through FFFFxxxx
-static const int MaxSystemRegisters = 0x400; // FF0x0000 through FF0x0FFC
+static constexpr int MaxSystemTables = 256; // FF00xxxx through FFFFxxxx
+static constexpr int MaxSystemRegisters = 0x400; // FF0x0000 through FF0x0FFC
void r9751_state::system_trace_init()
{
const SystemRegisterInfo*** trace_context;
@@ -698,7 +699,7 @@ WRITE32_MEMBER( r9751_state::r9751_mmio_5ff_w )
case 0x0198: // SMIOC soft reset?
// It's not clear what exactly this register write does.
// It isn't a soft reset of the SMIOC because the 68k does not wait long enough for the SMIOC to finish rebooting.
- // Also the 68k does this twice in succession, with a status clear in between.
+ // Also the 68k does this twice in succession, with a status clear in between.
// The theory now is that a write to this register causes the status registers on the SMIOC to be
// set to the magic value 0x0100 (which is set after initialization is complete) - which serves as a trigger
// for the disktool software to reinitialize the SMIOC and proceed into a working state.
diff --git a/src/mame/drivers/rainbow.cpp b/src/mame/drivers/rainbow.cpp
index 61656757fdf..45b6bdda883 100644
--- a/src/mame/drivers/rainbow.cpp
+++ b/src/mame/drivers/rainbow.cpp
@@ -3288,7 +3288,7 @@ MACHINE_CONFIG_START(rainbow_state::rainbow)
// Always set seek complete and track 00 signal (not super clean, but does not affect operation):
m_hdc->in_sc_callback().set_constant(1); // SEEK COMPLETE (VCC = complete)
- m_hdc->in_tk000_callback().set_constant(1); // TRACK 00 signal (= from drive)
+ m_hdc->in_tk000_callback().set_constant(1); // TRACK 00 signal (= from drive)
MCFG_HARDDISK_ADD("decharddisk1")
/// ******************************** / HARD DISK CONTROLLER ****************************************
diff --git a/src/mame/drivers/scobra.cpp b/src/mame/drivers/scobra.cpp
index 6fa9db7ff87..fbbf5b6d598 100644
--- a/src/mame/drivers/scobra.cpp
+++ b/src/mame/drivers/scobra.cpp
@@ -1285,7 +1285,7 @@ ROM_START( tazmaniet )
ROM_LOAD( "prom.bin", 0x0000, 0x0020, CRC(aa1f7f5e) SHA1(311dd17aa11490a1173c76223e4ccccf8ea29850) ) // same as hustler?! Gives wrong colors
ROM_REGION( 0x200, "unused_proms", 0) // TODO: are these the correct color PROMs?
- ROM_LOAD( "13209.prom", 0x0000, 0x0100, CRC(da1708c9) SHA1(b2633eba050866c6f555ed0fd9be369d69f13683) )
+ ROM_LOAD( "13209.prom", 0x0000, 0x0100, CRC(da1708c9) SHA1(b2633eba050866c6f555ed0fd9be369d69f13683) )
ROM_LOAD( "13210.prom", 0x0100, 0x0100, CRC(e54d042a) SHA1(e3259b5c178fc5ab43eda27f07107b65555512d3) )
ROM_END
diff --git a/src/mame/drivers/segas32.cpp b/src/mame/drivers/segas32.cpp
index 3631259645f..ce7f2f0ffce 100644
--- a/src/mame/drivers/segas32.cpp
+++ b/src/mame/drivers/segas32.cpp
@@ -3729,6 +3729,9 @@ ROM_END
**************************************************************************************************************************
F1 Super Lap (Export)
protected via FD1149 317-0210
+ GAME BD NO. 833-9407-02 F1 SUPER LAP
+ ROM BD. 834-9408-02
+ A/D BD NO. 837-7536
*/
ROM_START( f1lap )
ROM_REGION( 0x200000, "mainpcb:maincpu", 0 ) /* v60 code + data */
diff --git a/src/mame/drivers/snesb.cpp b/src/mame/drivers/snesb.cpp
index f656cc8d8ee..341cbd77633 100644
--- a/src/mame/drivers/snesb.cpp
+++ b/src/mame/drivers/snesb.cpp
@@ -1056,33 +1056,33 @@ void snesb_state::init_rushbeat()
uint8_t *dst = memregion("user3")->base();
static const uint8_t address_tab_high[32] = {
- 0x0b, 0x1d, 0x05, 0x15, 0x09, 0x19, 0x04, 0x13, 0x02, 0x1f, 0x07, 0x17, 0x0d, 0x11, 0x0a, 0x1a,
- 0x14, 0x0e, 0x18, 0x06, 0x1e, 0x01, 0x10, 0x0c, 0x1b, 0x0f, 0x16, 0x00, 0x12, 0x08, 0x1c, 0x03
+ 0x0b, 0x1d, 0x05, 0x15, 0x09, 0x19, 0x04, 0x13, 0x02, 0x1f, 0x07, 0x17, 0x0d, 0x11, 0x0a, 0x1a,
+ 0x14, 0x0e, 0x18, 0x06, 0x1e, 0x01, 0x10, 0x0c, 0x1b, 0x0f, 0x16, 0x00, 0x12, 0x08, 0x1c, 0x03
};
static const uint8_t address_tab_low[64] = {
- 0x14, 0x1d, 0x11, 0x3c, 0x0a, 0x29, 0x2d, 0x2e, 0x30, 0x32, 0x16, 0x36, 0x05, 0x25, 0x26, 0x37,
- 0x20, 0x21, 0x27, 0x28, 0x33, 0x34, 0x23, 0x12, 0x1e, 0x1f, 0x3b, 0x24, 0x2c, 0x35, 0x38, 0x39,
- 0x3d, 0x0c, 0x2a, 0x0d, 0x22, 0x18, 0x19, 0x1a, 0x03, 0x08, 0x04, 0x3a, 0x0b, 0x0f, 0x15, 0x17,
- 0x1b, 0x13, 0x00, 0x1c, 0x2b, 0x01, 0x06, 0x2f, 0x07, 0x09, 0x02, 0x31, 0x10, 0x0e, 0x3f, 0x3e
+ 0x14, 0x1d, 0x11, 0x3c, 0x0a, 0x29, 0x2d, 0x2e, 0x30, 0x32, 0x16, 0x36, 0x05, 0x25, 0x26, 0x37,
+ 0x20, 0x21, 0x27, 0x28, 0x33, 0x34, 0x23, 0x12, 0x1e, 0x1f, 0x3b, 0x24, 0x2c, 0x35, 0x38, 0x39,
+ 0x3d, 0x0c, 0x2a, 0x0d, 0x22, 0x18, 0x19, 0x1a, 0x03, 0x08, 0x04, 0x3a, 0x0b, 0x0f, 0x15, 0x17,
+ 0x1b, 0x13, 0x00, 0x1c, 0x2b, 0x01, 0x06, 0x2f, 0x07, 0x09, 0x02, 0x31, 0x10, 0x0e, 0x3f, 0x3e
};
static const uint8_t data_table[256] = {
- 0xac, 0x85, 0xe5, 0xa4, 0xe4, 0xed, 0xad, 0xa5, 0xcd, 0x84, 0x8c, 0xcc, 0xc5, 0xec, 0x8d, 0xc4,
- 0x38, 0x11, 0x71, 0x30, 0x70, 0x79, 0x39, 0x31, 0x59, 0x10, 0x18, 0x58, 0x51, 0x78, 0x19, 0x50,
- 0xba, 0x93, 0xf3, 0xb2, 0xf2, 0xfb, 0xbb, 0xb3, 0xdb, 0x92, 0x9a, 0xda, 0xd3, 0xfa, 0x9b, 0xd2,
- 0xa8, 0x81, 0xe1, 0xa0, 0xe0, 0xe9, 0xa9, 0xa1, 0xc9, 0x80, 0x88, 0xc8, 0xc1, 0xe8, 0x89, 0xc0,
- 0xaa, 0x83, 0xe3, 0xa2, 0xe2, 0xeb, 0xab, 0xa3, 0xcb, 0x82, 0x8a, 0xca, 0xc3, 0xea, 0x8b, 0xc2,
- 0xbe, 0x97, 0xf7, 0xb6, 0xf6, 0xff, 0xbf, 0xb7, 0xdf, 0x96, 0x9e, 0xde, 0xd7, 0xfe, 0x9f, 0xd6,
- 0xbc, 0x95, 0xf5, 0xb4, 0xf4, 0xfd, 0xbd, 0xb5, 0xdd, 0x94, 0x9c, 0xdc, 0xd5, 0xfc, 0x9d, 0xd4,
- 0xb8, 0x91, 0xf1, 0xb0, 0xf0, 0xf9, 0xb9, 0xb1, 0xd9, 0x90, 0x98, 0xd8, 0xd1, 0xf8, 0x99, 0xd0,
- 0x3e, 0x17, 0x77, 0x36, 0x76, 0x7f, 0x3f, 0x37, 0x5f, 0x16, 0x1e, 0x5e, 0x57, 0x7e, 0x1f, 0x56,
- 0x28, 0x01, 0x61, 0x20, 0x60, 0x69, 0x29, 0x21, 0x49, 0x00, 0x08, 0x48, 0x41, 0x68, 0x09, 0x40,
- 0x2c, 0x05, 0x65, 0x24, 0x64, 0x6d, 0x2d, 0x25, 0x4d, 0x04, 0x0c, 0x4c, 0x45, 0x6c, 0x0d, 0x44,
- 0x2e, 0x07, 0x67, 0x26, 0x66, 0x6f, 0x2f, 0x27, 0x4f, 0x06, 0x0e, 0x4e, 0x47, 0x6e, 0x0f, 0x46,
- 0x3a, 0x13, 0x73, 0x32, 0x72, 0x7b, 0x3b, 0x33, 0x5b, 0x12, 0x1a, 0x5a, 0x53, 0x7a, 0x1b, 0x52,
- 0xae, 0x87, 0xe7, 0xa6, 0xe6, 0xef, 0xaf, 0xa7, 0xcf, 0x86, 0x8e, 0xce, 0xc7, 0xee, 0x8f, 0xc6,
- 0x3c, 0x15, 0x75, 0x34, 0x74, 0x7d, 0x3d, 0x35, 0x5d, 0x14, 0x1c, 0x5c, 0x55, 0x7c, 0x1d, 0x54,
+ 0xac, 0x85, 0xe5, 0xa4, 0xe4, 0xed, 0xad, 0xa5, 0xcd, 0x84, 0x8c, 0xcc, 0xc5, 0xec, 0x8d, 0xc4,
+ 0x38, 0x11, 0x71, 0x30, 0x70, 0x79, 0x39, 0x31, 0x59, 0x10, 0x18, 0x58, 0x51, 0x78, 0x19, 0x50,
+ 0xba, 0x93, 0xf3, 0xb2, 0xf2, 0xfb, 0xbb, 0xb3, 0xdb, 0x92, 0x9a, 0xda, 0xd3, 0xfa, 0x9b, 0xd2,
+ 0xa8, 0x81, 0xe1, 0xa0, 0xe0, 0xe9, 0xa9, 0xa1, 0xc9, 0x80, 0x88, 0xc8, 0xc1, 0xe8, 0x89, 0xc0,
+ 0xaa, 0x83, 0xe3, 0xa2, 0xe2, 0xeb, 0xab, 0xa3, 0xcb, 0x82, 0x8a, 0xca, 0xc3, 0xea, 0x8b, 0xc2,
+ 0xbe, 0x97, 0xf7, 0xb6, 0xf6, 0xff, 0xbf, 0xb7, 0xdf, 0x96, 0x9e, 0xde, 0xd7, 0xfe, 0x9f, 0xd6,
+ 0xbc, 0x95, 0xf5, 0xb4, 0xf4, 0xfd, 0xbd, 0xb5, 0xdd, 0x94, 0x9c, 0xdc, 0xd5, 0xfc, 0x9d, 0xd4,
+ 0xb8, 0x91, 0xf1, 0xb0, 0xf0, 0xf9, 0xb9, 0xb1, 0xd9, 0x90, 0x98, 0xd8, 0xd1, 0xf8, 0x99, 0xd0,
+ 0x3e, 0x17, 0x77, 0x36, 0x76, 0x7f, 0x3f, 0x37, 0x5f, 0x16, 0x1e, 0x5e, 0x57, 0x7e, 0x1f, 0x56,
+ 0x28, 0x01, 0x61, 0x20, 0x60, 0x69, 0x29, 0x21, 0x49, 0x00, 0x08, 0x48, 0x41, 0x68, 0x09, 0x40,
+ 0x2c, 0x05, 0x65, 0x24, 0x64, 0x6d, 0x2d, 0x25, 0x4d, 0x04, 0x0c, 0x4c, 0x45, 0x6c, 0x0d, 0x44,
+ 0x2e, 0x07, 0x67, 0x26, 0x66, 0x6f, 0x2f, 0x27, 0x4f, 0x06, 0x0e, 0x4e, 0x47, 0x6e, 0x0f, 0x46,
+ 0x3a, 0x13, 0x73, 0x32, 0x72, 0x7b, 0x3b, 0x33, 0x5b, 0x12, 0x1a, 0x5a, 0x53, 0x7a, 0x1b, 0x52,
+ 0xae, 0x87, 0xe7, 0xa6, 0xe6, 0xef, 0xaf, 0xa7, 0xcf, 0x86, 0x8e, 0xce, 0xc7, 0xee, 0x8f, 0xc6,
+ 0x3c, 0x15, 0x75, 0x34, 0x74, 0x7d, 0x3d, 0x35, 0x5d, 0x14, 0x1c, 0x5c, 0x55, 0x7c, 0x1d, 0x54,
0x2a, 0x03, 0x63, 0x22, 0x62, 0x6b, 0x2b, 0x23, 0x4b, 0x02, 0x0a, 0x4a, 0x43, 0x6a, 0x0b, 0x42
};
diff --git a/src/mame/drivers/snk.cpp b/src/mame/drivers/snk.cpp
index 6f785985e91..c30141723be 100644
--- a/src/mame/drivers/snk.cpp
+++ b/src/mame/drivers/snk.cpp
@@ -3281,9 +3281,10 @@ static INPUT_PORTS_START( tdfever )
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_START("DSW1")
- PORT_DIPNAME( 0x01, 0x00, DEF_STR( Allow_Continue ) ) PORT_DIPLOCATION("DSW1:1")
- PORT_DIPSETTING( 0x01, DEF_STR( No ) )
- PORT_DIPSETTING( 0x00, DEF_STR( Yes ) )
+ // TODO: tdfever2 has different dip switches (at least allow continue seems ignored)
+ PORT_DIPNAME( 0x01, 0x01, DEF_STR( Allow_Continue ) ) PORT_DIPLOCATION("DSW1:1")
+ PORT_DIPSETTING( 0x00, DEF_STR( No ) )
+ PORT_DIPSETTING( 0x01, DEF_STR( Yes ) )
PORT_DIPNAME( 0x02, 0x02, DEF_STR( Cabinet ) ) PORT_DIPLOCATION("DSW1:2")
PORT_DIPSETTING( 0x02, "2 Player Upright" )
PORT_DIPSETTING( 0x00, "4 Player Cocktail" )
diff --git a/src/mame/drivers/splus.cpp b/src/mame/drivers/splus.cpp
index 969eeada1f7..b796171f60f 100644
--- a/src/mame/drivers/splus.cpp
+++ b/src/mame/drivers/splus.cpp
@@ -711,6 +711,23 @@ MACHINE_CONFIG_END
* Rom Load *
*************************/
+ROM_START( spset005 ) /* Set Chip, not sure how it works but archive for future use */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "set005.u52", 0x00000, 0x10000, CRC(43b70e2e) SHA1(30d610c988fc7e7e9fd54ff378c4a1fecfe5fffe) ) /* 09/24/93 @ IGT L93-1769 */
+ ROM_LOAD( "set017.u52", 0x00000, 0x10000, NO_DUMP ) /* When dumped make a seperate romdef */
+ ROM_LOAD( "set020.u52", 0x00000, 0x10000, NO_DUMP ) /* When dumped make a seperate romdef */
+ROM_END
+
+ROM_START( spset015 ) /* Set Chip, not sure how it works but archive for future use */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "set015.u52", 0x00000, 0x10000, CRC(01641946) SHA1(81a0632ef96731907b28963293ab12db2073f4a6) )
+ROM_END
+
+ROM_START( spset026 ) /* Set Chip, not sure how it works but archive for future use */
+ ROM_REGION( 0x10000, "maincpu", 0 )
+ ROM_LOAD( "set026.u52", 0x00000, 0x10000, CRC(01641946) SHA1(81a0632ef96731907b28963293ab12db2073f4a6) ) /* 11/06/96 @ IGT NV */
+ROM_END
+
ROM_START( spss4240 ) /* Coral Reef (SS4240) */
ROM_REGION( 0x10000, "maincpu", 0 )
ROM_LOAD( "sp1271.u52", 0x00000, 0x10000, CRC(dc164599) SHA1(7114652a733b26cd711dbe4d65dde065ba73619f) )
@@ -724,4 +741,8 @@ ROM_END
*************************/
// YEAR NAME PARENT MACHINE INPUT CLASS INIT ROT COMPANY FULLNAME FLAGS LAYOUT
+GAMEL( 1993, spset005, 0, splus, splus, splus_state, init_splus, ROT0, "IGT - International Game Technology", "S-Plus SET005 Set chip", MACHINE_NOT_WORKING, layout_splus )
+GAMEL( 1993, spset015, 0, splus, splus, splus_state, init_splus, ROT0, "IGT - International Game Technology", "S-Plus SET015 Set chip", MACHINE_NOT_WORKING, layout_splus )
+GAMEL( 1996, spset026, 0, splus, splus, splus_state, init_splus, ROT0, "IGT - International Game Technology", "S-Plus SET026 Set chip", MACHINE_NOT_WORKING, layout_splus )
+
GAMEL( 1994, spss4240, 0, splus, splus, splus_state, init_splus, ROT0, "IGT - International Game Technology", "S-Plus (SS4240) Coral Reef", MACHINE_NOT_WORKING, layout_splus )
diff --git a/src/mame/drivers/supertnk.cpp b/src/mame/drivers/supertnk.cpp
index 0493f3c9ca0..7010cf67d04 100644
--- a/src/mame/drivers/supertnk.cpp
+++ b/src/mame/drivers/supertnk.cpp
@@ -130,8 +130,8 @@ public:
private:
DECLARE_WRITE_LINE_MEMBER(bankswitch_0_w);
DECLARE_WRITE_LINE_MEMBER(bankswitch_1_w);
- DECLARE_WRITE8_MEMBER(interrupt_ack_w);
- DECLARE_WRITE_LINE_MEMBER(watchdog_enable_w);
+ DECLARE_WRITE_LINE_MEMBER(interrupt_enable_w);
+ DECLARE_WRITE_LINE_MEMBER(watchdog_reset_w);
DECLARE_WRITE8_MEMBER(videoram_w);
DECLARE_READ8_MEMBER(videoram_r);
DECLARE_WRITE_LINE_MEMBER(bitplane_select_0_w);
@@ -149,6 +149,7 @@ private:
uint8_t m_rom_bank;
uint8_t m_bitplane_select;
pen_t m_pens[NUM_PENS];
+ bool m_interrupt_enable;
required_device<cpu_device> m_maincpu;
required_device<watchdog_timer_device> m_watchdog;
@@ -190,20 +191,22 @@ WRITE_LINE_MEMBER(supertnk_state::bankswitch_1_w)
WRITE_LINE_MEMBER(supertnk_state::vblank_interrupt)
{
- if (state)
+ if (state && m_interrupt_enable)
m_maincpu->set_input_line(INT_9980A_LEVEL4, ASSERT_LINE);
}
-WRITE8_MEMBER(supertnk_state::interrupt_ack_w)
+WRITE_LINE_MEMBER(supertnk_state::interrupt_enable_w)
{
- m_maincpu->set_input_line(INT_9980A_LEVEL4, CLEAR_LINE);
+ m_interrupt_enable = state;
+ if (!state)
+ m_maincpu->set_input_line(INT_9980A_LEVEL4, CLEAR_LINE);
}
-WRITE_LINE_MEMBER(supertnk_state::watchdog_enable_w)
+WRITE_LINE_MEMBER(supertnk_state::watchdog_reset_w)
{
- m_watchdog->watchdog_enable(state);
+ m_watchdog->watchdog_enable(!state);
}
@@ -345,7 +348,6 @@ void supertnk_state::supertnk_io_map(address_map &map)
{
map(0x0000, 0x0000).nopw();
map(0x0400, 0x0407).w("outlatch", FUNC(ls259_device::write_d0));
- map(0x0406, 0x0406).w(FUNC(supertnk_state::interrupt_ack_w));
}
@@ -449,20 +451,16 @@ MACHINE_CONFIG_START(supertnk_state::supertnk)
outlatch.q_out_cb<1>().set(FUNC(supertnk_state::bitplane_select_1_w));
outlatch.q_out_cb<2>().set(FUNC(supertnk_state::bankswitch_0_w));
outlatch.q_out_cb<4>().set(FUNC(supertnk_state::bankswitch_1_w));
- //outlatch.q_out_cb<6>().set(FUNC(supertnk_state::interrupt_enable_w));
- outlatch.q_out_cb<7>().set(FUNC(supertnk_state::watchdog_enable_w));
+ outlatch.q_out_cb<6>().set(FUNC(supertnk_state::watchdog_reset_w)).invert();
+ outlatch.q_out_cb<7>().set(FUNC(supertnk_state::interrupt_enable_w));
WATCHDOG_TIMER(config, m_watchdog);
/* video hardware */
-
- MCFG_SCREEN_ADD("screen", RASTER)
- MCFG_SCREEN_SIZE(32*8, 32*8)
- MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 0*8, 32*8-1)
- MCFG_SCREEN_REFRESH_RATE(60)
- MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0))
- MCFG_SCREEN_UPDATE_DRIVER(supertnk_state, screen_update)
- MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(*this, supertnk_state, vblank_interrupt))
+ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
+ screen.set_raw(20.79_MHz_XTAL / 4, 330, 0, 32*8, 315, 0, 32*8); // parameters guessed
+ screen.set_screen_update(FUNC(supertnk_state::screen_update));
+ screen.screen_vblank().set(FUNC(supertnk_state::vblank_interrupt));
/* audio hardware */
SPEAKER(config, "mono").front_center();
diff --git a/src/mame/drivers/tecmo16.cpp b/src/mame/drivers/tecmo16.cpp
index 9e2682cd4b9..7ab3910dd28 100644
--- a/src/mame/drivers/tecmo16.cpp
+++ b/src/mame/drivers/tecmo16.cpp
@@ -59,7 +59,7 @@ void tecmo16_state::fstarfrc_map(address_map &map)
map(0x150030, 0x150031).portr("DSW2").nopw(); /* ??? */
map(0x150040, 0x150041).portr("DSW1");
map(0x150050, 0x150051).portr("P1_P2");
-// map(0x160000, 0x160001).nopr(); /* ??? Read at every scene changes */
+// map(0x160000, 0x160001).nopr(); /* ??? Read at every scene changes */
map(0x160000, 0x160001).w(FUNC(tecmo16_state::scroll_char_x_w));
map(0x16000c, 0x16000d).w(FUNC(tecmo16_state::scroll_x_w));
map(0x160012, 0x160013).w(FUNC(tecmo16_state::scroll_y_w));
diff --git a/src/mame/drivers/tehkanwc.cpp b/src/mame/drivers/tehkanwc.cpp
index b593cb8323c..36b167acca9 100644
--- a/src/mame/drivers/tehkanwc.cpp
+++ b/src/mame/drivers/tehkanwc.cpp
@@ -1007,7 +1007,7 @@ ROM_END
/* There are some dumps out there that only have the year hacked to 1986 and a little bunch of bytes
from the graphics zone. I think that not worth to support these hacks...
*/
-
+
GAME( 1985, tehkanwc, 0, tehkanwc, tehkanwc, tehkanwc_state, empty_init, ROT0, "Tehkan", "Tehkan World Cup (set 1)", MACHINE_SUPPORTS_SAVE )
GAME( 1985, tehkanwcb, tehkanwc, tehkanwcb,tehkanwc, tehkanwc_state, empty_init, ROT0, "Tehkan", "Tehkan World Cup (set 2, bootleg?)", MACHINE_SUPPORTS_SAVE )
diff --git a/src/mame/drivers/toypop.cpp b/src/mame/drivers/toypop.cpp
index bb0df1deba2..30b26b46094 100644
--- a/src/mame/drivers/toypop.cpp
+++ b/src/mame/drivers/toypop.cpp
@@ -43,8 +43,8 @@
class namcos16_state : public driver_device
{
public:
- namcos16_state(const machine_config &mconfig, device_type type, const char *tag)
- : driver_device(mconfig, type, tag),
+ namcos16_state(const machine_config &mconfig, device_type type, const char *tag) :
+ driver_device(mconfig, type, tag),
m_master_cpu(*this,"maincpu"),
m_slave_cpu(*this, "slave"),
m_sound_cpu(*this, "audiocpu"),
@@ -59,7 +59,8 @@ public:
m_bgvram(*this, "bgvram"),
m_fgvram(*this, "fgvram"),
m_fgattr(*this, "fgattr")
- { }
+ {
+ }
void toypop(machine_config &config);
void liblrabl(machine_config &config);
@@ -123,9 +124,9 @@ private:
bool m_slave_irq_enable;
uint8_t m_pal_bank;
- void legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip);
- void legacy_fg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip);
- void legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip);
+ void legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip);
+ void legacy_fg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip);
+ void legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip);
};
PALETTE_INIT_MEMBER(namcos16_state, toypop)
@@ -177,27 +178,22 @@ PALETTE_INIT_MEMBER(namcos16_state, toypop)
}
}
-void namcos16_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip)
+void namcos16_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip)
{
- int x, y;
const uint16_t pal_base = 0x300 + (m_pal_bank << 4);
const uint32_t src_base = 0x200/2;
const uint16_t src_pitch = 288 / 2;
- for (y = cliprect.min_y; y <= cliprect.max_y; ++y)
+ for (int y = cliprect.min_y; y <= cliprect.max_y; ++y)
{
uint16_t *src = &m_bgvram[y * src_pitch + cliprect.min_x + src_base];
- uint16_t *dst;
- if(!flip)
- dst = &bitmap.pix16(y, cliprect.min_x);
- else
- dst = &bitmap.pix16(cliprect.max_y - y, cliprect.max_x);
+ uint16_t *dst = &bitmap.pix16(flip ? (cliprect.max_y - y) : y, flip ? cliprect.max_x : cliprect.min_x);
- for (x = cliprect.min_x; x <= cliprect.max_x; x += 2)
+ for (int x = cliprect.min_x; x <= cliprect.max_x; x += 2)
{
- uint32_t srcpix = *src++;
- int idx1 = ((srcpix >> 8) & 0xf) + pal_base;
- int idx2 = (srcpix & 0xf) + pal_base;
+ uint32_t const srcpix = *src++;
+ int const idx1 = ((srcpix >> 8) & 0xf) + pal_base;
+ int const idx2 = (srcpix & 0xf) + pal_base;
if (!flip)
{
*dst++ = m_palette->pen(idx1);
@@ -212,62 +208,63 @@ void namcos16_state::legacy_bg_draw(bitmap_ind16 &bitmap,const rectangle &clipre
}
}
-void namcos16_state::legacy_fg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip)
+void namcos16_state::legacy_fg_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip)
{
- gfx_element *gfx_0 = m_gfxdecode->gfx(0);
- int count;
+ gfx_element *const gfx_0 = m_gfxdecode->gfx(0);
- for (count=0;count<32*32;count++)
+ for (int count = 0; count < 32*32; count++)
{
+ int const xoffs(count >> 5);
+ int const yoffs(count & 0x1f);
int x;// = (count % 32);
int y; //= count / 32;
if (!flip)
{
- if(count < 64)
+ if (count < 64)
{
- x = 34 + (count / 32);
- y = (count % 32) - 2;
+ x = 34 + xoffs;
+ y = yoffs - 2;
}
- else if(count >= 32*30)
+ else if (count >= 32*30)
{
- x = (count / 32) - 30;
- y = (count % 32) - 2;
+ x = xoffs - 30;
+ y = yoffs - 2;
}
else
{
- x = 2 + (count % 32);
- y = (count / 32) - 2;
+ x = 2 + yoffs;
+ y = xoffs - 2;
}
}
else
{
- if(count < 64)
+ if (count < 64)
{
- x = 1 - (count / 32);
- y = 29 - (count % 32);
+ x = 1 - xoffs;
+ y = 29 - yoffs;
}
- else if(count >= 32*30)
+ else if (count >= 32*30)
{
- x = 65 - (count / 32);
- y = 29 - (count % 32);
+ x = 65 - xoffs;
+ y = 29 - yoffs;
}
else
{
- x = 33 - (count % 32);
- y = 29 - (count / 32);
+ x = 33 - yoffs;
+ y = 29 - xoffs;
}
}
uint16_t tile = m_fgvram[count];
- uint8_t color = (m_fgattr[count] & 0x3f) + (m_pal_bank<<6);
+ uint8_t color = (m_fgattr[count] & 0x3f) + (m_pal_bank << 6);
- gfx_0->transpen(bitmap,cliprect,tile,color,flip,flip,x*8,y*8,0);
+ gfx_0->transpen(bitmap, cliprect, tile, color, flip, flip, x*8, y*8, 0);
}
}
// TODO: this is likely to be a lot more complex, and maybe is per scanline too
-void namcos16_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,int flip)
+void namcos16_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &cliprect,bool flip)
{
gfx_element *gfx_1 = m_gfxdecode->gfx(1);
int count;
@@ -309,12 +306,12 @@ void namcos16_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &clipr
fy ^= 1;
}
- if(height == 2)
+ if (height == 2)
y -=16;
- for(int yi=0;yi<height;yi++)
+ for (int yi=0; yi<height; yi++)
{
- for(int xi=0;xi<width;xi++)
+ for(int xi=0; xi<width; xi++)
{
uint16_t sprite_offs = tile + gfx_offs[yi ^ ((height - 1) * fy)][xi ^ ((width - 1) * fx)];
gfx_1->transmask(bitmap,cliprect,sprite_offs,color,fx,fy,x + xi*16,y + yi *16,m_palette->transpen_mask(*gfx_1, color, 0xff));
@@ -325,7 +322,7 @@ void namcos16_state::legacy_obj_draw(bitmap_ind16 &bitmap,const rectangle &clipr
uint32_t namcos16_state::screen_update( screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect )
{
- int flip = flip_screen();
+ bool const flip = flip_screen();
legacy_bg_draw(bitmap,cliprect,flip);
legacy_fg_draw(bitmap,cliprect,flip);
legacy_obj_draw(bitmap,cliprect,flip);
diff --git a/src/mame/drivers/twins.cpp b/src/mame/drivers/twins.cpp
index 54abeb2a6b6..fe7135a4f46 100644
--- a/src/mame/drivers/twins.cpp
+++ b/src/mame/drivers/twins.cpp
@@ -445,7 +445,7 @@ MACHINE_CONFIG_START(twins_state::twinsed1)
MACHINE_CONFIG_END
-/* The Ecogames set and the Electronic Devices second set has different palette hardware
+/* The Ecogames set and the Electronic Devices second set has different palette hardware
and a different port map than Electronic Devices first set */
void twins_state::twins_io(address_map &map)
diff --git a/src/mame/drivers/vgmplay.cpp b/src/mame/drivers/vgmplay.cpp
index ca168193182..d3d64d38d59 100644
--- a/src/mame/drivers/vgmplay.cpp
+++ b/src/mame/drivers/vgmplay.cpp
@@ -1524,8 +1524,8 @@ void vgmplay_device::execute_run()
}
//else if ((offset & 0x7f) == 0x15 && m_nes_apu_channel_hack[index] == -2 && (m_file->read_byte(m_pc + 2) & 0x1f) != 0)
//{
- // osd_printf_error("bad rip false positive, late enabling nesapu.%d channels %x/%x\n", index, m_pc, m_io->read_dword(REG_SIZE));
- // m_nes_apu_channel_hack[index] = -1;
+ // osd_printf_error("bad rip false positive, late enabling nesapu.%d channels %x/%x\n", index, m_pc, m_io->read_dword(REG_SIZE));
+ // m_nes_apu_channel_hack[index] = -1;
//}
if (offset & 0x80)
diff --git a/src/mame/drivers/vii.cpp b/src/mame/drivers/vii.cpp
index a7ffd7d4ef5..0239e9f48fc 100644
--- a/src/mame/drivers/vii.cpp
+++ b/src/mame/drivers/vii.cpp
@@ -345,20 +345,20 @@ void vsmile_state::device_timer(emu_timer &timer, device_timer_id id, int param,
}
}
-#define VSMILE_PORTB_CS1 0x0001
-#define VSMILE_PORTB_CS2 0x0002
-#define VSMILE_PORTB_CART 0x0004
-#define VSMILE_PORTB_RESET 0x0008
-#define VSMILE_PORTB_FRONT24 0x0010
-#define VSMILE_PORTB_OFF 0x0020
-#define VSMILE_PORTB_OFF_SW 0x0040
-#define VSMILE_PORTB_ON_SW 0x0080
-
-#define VSMILE_PORTC_VER 0x000f
-#define VSMILE_PORTC_LOGO 0x0010
-#define VSMILE_PORTC_TEST 0x0020
-#define VSMILE_PORTC_AMP 0x0040
-#define VSMILE_PORTC_SYSRESET 0x0080
+#define VSMILE_PORTB_CS1 0x0001
+#define VSMILE_PORTB_CS2 0x0002
+#define VSMILE_PORTB_CART 0x0004
+#define VSMILE_PORTB_RESET 0x0008
+#define VSMILE_PORTB_FRONT24 0x0010
+#define VSMILE_PORTB_OFF 0x0020
+#define VSMILE_PORTB_OFF_SW 0x0040
+#define VSMILE_PORTB_ON_SW 0x0080
+
+#define VSMILE_PORTC_VER 0x000f
+#define VSMILE_PORTC_LOGO 0x0010
+#define VSMILE_PORTC_TEST 0x0020
+#define VSMILE_PORTC_AMP 0x0040
+#define VSMILE_PORTC_SYSRESET 0x0080
READ16_MEMBER(vsmile_state::bank0_r)
{
diff --git a/src/mame/drivers/xavix.cpp b/src/mame/drivers/xavix.cpp
index f66468e464a..34fcb313409 100644
--- a/src/mame/drivers/xavix.cpp
+++ b/src/mame/drivers/xavix.cpp
@@ -509,10 +509,10 @@ INPUT_PORTS_END
/*
static INPUT_PORTS_START( xavixp )
- PORT_INCLUDE(xavix)
+ PORT_INCLUDE(xavix)
- PORT_MODIFY("REGION") // PAL/NTSC flag
- PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM )
+ PORT_MODIFY("REGION") // PAL/NTSC flag
+ PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_CUSTOM )
INPUT_PORTS_END
*/
@@ -555,7 +555,7 @@ static INPUT_PORTS_START( rad_crdn )
PORT_MODIFY("IN0")
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON1 )
- PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON2 )
+ PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON2 )
PORT_MODIFY("IN1")
PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
@@ -603,11 +603,11 @@ static INPUT_PORTS_START( rad_bass )
PORT_MODIFY("IN0")
PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_BUTTON1 )
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_JOYSTICK_UP )
- PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
+ PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN )
PORT_MODIFY("IN1")
PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT )
- PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
+ PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT )
PORT_BIT( 0x40, IP_ACTIVE_HIGH, IPT_POWER_OFF ) PORT_NAME("Power Switch") // pressing this will turn the game off.
INPUT_PORTS_END
@@ -939,7 +939,7 @@ ROM_END
/*
The e-kara cartridges require the BIOS rom to map into 2nd external bus space as they fetch palette data from
- it etc.
+ it etc.
*/
#define EKARA_BASE_ROM \
diff --git a/src/mame/includes/bbc.h b/src/mame/includes/bbc.h
index a6d9b6df214..6af426330e0 100644
--- a/src/mame/includes/bbc.h
+++ b/src/mame/includes/bbc.h
@@ -85,7 +85,7 @@ public:
, m_extube(*this, "extube")
, m_1mhzbus(*this, "1mhzbus")
, m_userport(*this, "userport")
-// , m_internal(*this, "internal")
+// , m_internal(*this, "internal")
, m_exp(*this, "exp")
, m_rtc(*this, "rtc")
, m_i2cmem(*this, "i2cmem")
diff --git a/src/mame/includes/ddragon.h b/src/mame/includes/ddragon.h
index edd90fa3493..eedfce5cf5c 100644
--- a/src/mame/includes/ddragon.h
+++ b/src/mame/includes/ddragon.h
@@ -152,7 +152,6 @@ private:
void dd2_sub_map(address_map &map);
void ddragon_map(address_map &map);
void ddragonba_sub_map(address_map &map);
- void ddragonba_sub_portmap(address_map &map);
void sound_map(address_map &map);
void sub_map(address_map &map);
};
diff --git a/src/mame/includes/namcos22.h b/src/mame/includes/namcos22.h
index f71d89872af..6d402f2cdd9 100644
--- a/src/mame/includes/namcos22.h
+++ b/src/mame/includes/namcos22.h
@@ -213,7 +213,7 @@ public:
m_p2(*this, "P2"),
m_mcup5a(*this, "MCUP5A"),
m_mcup5b(*this, "MCUP5B"),
- m_led(*this, "led"),
+ m_mcuout(*this, "mcuout%u", 0U),
m_cpuled(*this, "cpuled%u", 0U)
{ }
@@ -357,11 +357,8 @@ private:
DECLARE_READ8_MEMBER(mcu_port5_r);
DECLARE_WRITE8_MEMBER(mcu_port6_w);
DECLARE_READ8_MEMBER(mcu_port6_r);
- DECLARE_WRITE8_MEMBER(mcu_port7_w);
- DECLARE_READ8_MEMBER(mcu_port7_r);
DECLARE_READ8_MEMBER(namcos22s_mcu_adc_r);
- DECLARE_WRITE8_MEMBER(propcycle_mcu_port5_w);
- DECLARE_WRITE8_MEMBER(alpine_mcu_port5_w);
+ DECLARE_WRITE8_MEMBER(alpine_mcu_port4_w);
DECLARE_READ8_MEMBER(mcu_port4_s22_r);
DECLARE_READ8_MEMBER(iomcu_port4_s22_r);
DECLARE_READ16_MEMBER(mcu141_speedup_r);
@@ -463,7 +460,6 @@ private:
void mcu_s22_program(address_map &map);
void namcos22_am(address_map &map);
void namcos22s_am(address_map &map);
- void propcycl_io_map(address_map &map);
void slave_dsp_data(address_map &map);
void slave_dsp_io(address_map &map);
void slave_dsp_program(address_map &map);
@@ -494,7 +490,7 @@ private:
optional_ioport m_p2;
optional_ioport m_mcup5a;
optional_ioport m_mcup5b;
- output_finder<> m_led;
+ output_finder<16> m_mcuout;
output_finder<8> m_cpuled;
u8 m_syscontrol[0x20];
@@ -518,7 +514,8 @@ private:
int m_UploadDestIdx;
u32 m_alpinesa_protection;
int m_motor_status;
- int m_p4;
+ u8 m_mcu_iocontrol;
+ u8 m_mcu_outdata;
u16 m_su_82;
u16 m_keycus_id;
u16 m_keycus_rng;
diff --git a/src/mame/includes/xavix.h b/src/mame/includes/xavix.h
index d38c0f04de6..9f8b5e45c32 100644
--- a/src/mame/includes/xavix.h
+++ b/src/mame/includes/xavix.h
@@ -202,7 +202,7 @@ void superxavix_lowbus_map(address_map &map);
required_device<xavix_device> m_maincpu;
required_device<screen_device> m_screen;
-
+
uint8_t m_vectorenable;
uint8_t m_nmi_vector_lo_data;
uint8_t m_nmi_vector_hi_data;
@@ -235,7 +235,7 @@ void superxavix_lowbus_map(address_map &map);
uint8_t m_timer_baseval;
int16_t get_vectors(int which, int half);
-
+
// raster IRQ
TIMER_CALLBACK_MEMBER(interrupt_gen);
emu_timer *m_interrupt_timer;
diff --git a/src/mame/layout/hp9825.lay b/src/mame/layout/hp9825.lay
index d73603d07f7..d14ae34c20f 100644
--- a/src/mame/layout/hp9825.lay
+++ b/src/mame/layout/hp9825.lay
@@ -1,34 +1,41 @@
<?xml version="1.0"?>
+<!--
+license:CC0
+copyright-holders:Sven Schnelle
+Hewlett-Packard 9000/3xx Layout
+-->
<mamelayout version="2">
- <element name="dotmatrix5dot">
- <dotmatrix5dot>
- <color red="1.0" green="0" blue="0" />
- </dotmatrix5dot>
- </element>
- <element name="run_light" defstate="0">
- <disk state="0">
- <color red="0.25" green="0" blue="0" />
- </disk>
- <disk state="1">
- <color red="1.0" green="0" blue="0" />
- </disk>
- </element>
- <view name="32-char display">
- <bounds x="-5" y="0" width="289" height="7"/>
- <bezel name="run_light" element="run_light">
- <bounds x="-5" y="2" width="2" height="2"/>
- </bezel>
- <!-- 32 5x7 characters -->
- <repeat count="32">
- <param name="digitidx" start="0" increment="1" />
- <param name="digit_x" start="0.0" increment="9"/>
- <!-- Each of the 7 rows in a character -->
- <repeat count="7">
- <param name="rowidx" start="0" increment="1" />
- <bezel name="char_~digitidx~_~rowidx~" element="dotmatrix5dot" state="0">
- <bounds x="~digit_x~" y="~rowidx~" width="5" height="1" />
- </bezel>
- </repeat>
- </repeat>
- </view>
+ <element name="dotmatrix5dot">
+ <dotmatrix5dot>
+ <color red="1.0" green="0" blue="0" />
+ </dotmatrix5dot>
+ </element>
+
+ <element name="run_light" defstate="0">
+ <disk state="0">
+ <color red="0.25" green="0" blue="0" />
+ </disk>
+ <disk state="1">
+ <color red="1.0" green="0" blue="0" />
+ </disk>
+ </element>
+
+ <view name="32-char display">
+ <bounds x="-5" y="0" width="289" height="7"/>
+ <bezel name="run_light" element="run_light">
+ <bounds x="-5" y="2" width="2" height="2"/>
+ </bezel>
+ <!-- 32 5x7 characters -->
+ <repeat count="32">
+ <param name="digitidx" start="0" increment="1" />
+ <param name="digit_x" start="0.0" increment="9"/>
+ <!-- Each of the 7 rows in a character -->
+ <repeat count="7">
+ <param name="rowidx" start="0" increment="1" />
+ <bezel name="char_~digitidx~_~rowidx~" element="dotmatrix5dot" state="0">
+ <bounds x="~digit_x~" y="~rowidx~" width="5" height="1" />
+ </bezel>
+ </repeat>
+ </repeat>
+ </view>
</mamelayout>
diff --git a/src/mame/layout/hp9k_3xx.lay b/src/mame/layout/hp9k_3xx.lay
index ba3282dd122..5ea470b0156 100644
--- a/src/mame/layout/hp9k_3xx.lay
+++ b/src/mame/layout/hp9k_3xx.lay
@@ -52,8 +52,8 @@ Hewlett-Packard 9000/3xx Layout
<screen index="0"><bounds x="0" y="0" width="1024" height="768"/></screen>
</view>
<view name="XGA Screen">
- <screen index="0">
- <bounds x="0" y="0" width="1024" height="768" />
- </screen>
+ <screen index="0">
+ <bounds x="0" y="0" width="1024" height="768" />
+ </screen>
</view>
</mamelayout>
diff --git a/src/mame/layout/yosakdon.lay b/src/mame/layout/yosakdon.lay
new file mode 100644
index 00000000000..3d1e6f16c2b
--- /dev/null
+++ b/src/mame/layout/yosakdon.lay
@@ -0,0 +1,62 @@
+<?xml version="1.0"?>
+<mamelayout version="2">
+ <element name="overlay">
+ <rect>
+ <bounds left="0" top="0" right="80" bottom="17" />
+ <color red="0.125" green="1.0" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="100" top="0" right="224" bottom="17" />
+ <color red="1.0" green="0.2" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="75" top="0" right="146" bottom="40" />
+ <color red="0.25" green="1.0" blue="0.2" />
+ </rect>
+ <rect>
+ <bounds left="0" top="33" right="224" bottom="60" />
+ <color red="0.25" green="1.0" blue="0.2" />
+ </rect>
+ <rect>
+ <bounds left="0" top="56" right="224" bottom="96" />
+ <color red="0.3" green="0.4" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="0" top="96" right="224" bottom="130" />
+ <color red="0.125" green="1.0" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="0" top="128" right="224" bottom="160" />
+ <color red="1.0" green="1.0" blue="0.1" />
+ </rect>
+ <rect>
+ <bounds left="0" top="159" right="224" bottom="192" />
+ <color red="1.0" green="0.2" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="0" top="191" right="224" bottom="216" />
+ <color red="1.0" green="0.25" blue="0.25" />
+ </rect>
+ <rect>
+ <bounds left="0" top="215" right="224" bottom="259" />
+ <color red="0.125" green="1.0" blue="1.0" />
+ </rect>
+ <rect>
+ <bounds left="131" top="238" right="186" bottom="259" />
+ <color red="1.0" green="1.0" blue="0.125" />
+ </rect>
+ <rect>
+ <bounds left="0" top="232" right="224" bottom="239" />
+ <color red="1.0" green="0.25" blue="0.25" />
+ </rect>
+ </element>
+
+ <view name="Color Overlay">
+ <screen index="0">
+ <bounds x="0" y="0" width="3" height="4" />
+ </screen>
+ <overlay element="overlay">
+ <bounds x="0" y="0" width="3" height="4" />
+ </overlay>
+ </view>
+</mamelayout>
diff --git a/src/mame/machine/bbc.cpp b/src/mame/machine/bbc.cpp
index 35d64e69aa9..e62c66251eb 100644
--- a/src/mame/machine/bbc.cpp
+++ b/src/mame/machine/bbc.cpp
@@ -623,7 +623,7 @@ WRITE8_MEMBER(bbc_state::via_system_porta_w)
/* Write enable to the sound generator */
//if (!m_latch->q0_r() && m_sn)
//{
- // m_sn->write(m_via_system_porta);
+ // m_sn->write(m_via_system_porta);
//}
/* Keyboard write enable */
if (!m_latch->q3_r())
@@ -1332,7 +1332,7 @@ void bbc_state::setup_banks(memory_bank *membank, uint32_t shift)
/* TODO: expansion devices currently use machine().root_device(), add method to slot interfaces to return pointer to memregion("rom") */
//if (m_fdc->rom_region[i])
//{
- // membank->configure_entry(i, m_fdc->rom_region[i] + shift);
+ // membank->configure_entry(i, m_fdc->rom_region[i] + shift);
//}
/* romslots populated by user override expansion devices */
if (m_rom[i] && (rom_region = memregion(region_tag.assign(m_rom[i]->tag()).append(GENERIC_ROM_REGION_TAG).c_str())))
diff --git a/src/mame/machine/ibm6580_fdc.cpp b/src/mame/machine/ibm6580_fdc.cpp
index ac9e2db3fd8..b87fb8aba5c 100644
--- a/src/mame/machine/ibm6580_fdc.cpp
+++ b/src/mame/machine/ibm6580_fdc.cpp
@@ -44,8 +44,8 @@ MACHINE_CONFIG_START(dw_fdc_device::device_add_mconfig)
MCFG_DEVICE_ADD("ppi8255", I8255, 0)
UPD765A(config, "upd765", false, false);
-// m_upd_fdc->intrq_wr_callback().set("pic8259", FUNC(pic8259_device::ir4_w));
-// m_upd_fdc->drq_wr_callback().set("dma8257", FUNC(dma8257_device::XXX));
+// m_upd_fdc->intrq_wr_callback().set("pic8259", FUNC(pic8259_device::ir4_w));
+// m_upd_fdc->drq_wr_callback().set("dma8257", FUNC(dma8257_device::XXX));
// MCFG_FLOPPY_DRIVE_ADD(UPD765_TAG ":0", wangpc_floppies, "525dd", wangpc_state::floppy_formats)
// MCFG_FLOPPY_DRIVE_ADD(UPD765_TAG ":1", wangpc_floppies, "525dd", wangpc_state::floppy_formats)
MACHINE_CONFIG_END
diff --git a/src/mame/machine/kb_poisk1.h b/src/mame/machine/kb_poisk1.h
index e46aa5adbae..87b9eb8f044 100644
--- a/src/mame/machine/kb_poisk1.h
+++ b/src/mame/machine/kb_poisk1.h
@@ -37,7 +37,7 @@ INPUT_PORTS_START( poisk1_keyboard_v89 )
/*-2*/ PORT_BIT( 0x100, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("?-2 - .") /* PORT_CODE(KEYCODE_STOP) PORT_CHAR('.') PORT_CHAR('>') */
/*-3*/ PORT_BIT( 0x200, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("?-3 - _") /* PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-') PORT_CHAR('_') */
PORT_BIT( 0x400, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_P) PORT_CHAR('p') PORT_CHAR('P')
- PORT_BIT( 0x800, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_OPENBRACE) PORT_CHAR('[') PORT_CHAR('{') // scancode 0x54
+ PORT_BIT( 0x800, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_OPENBRACE) PORT_CHAR('[') PORT_CHAR('{') // scancode 0x54
PORT_START("Y3")
PORT_BIT( 0x001, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_CODE(KEYCODE_F) PORT_CHAR('f') PORT_CHAR('F')
diff --git a/src/mame/machine/ms7004.cpp b/src/mame/machine/ms7004.cpp
index 0039d212372..05804b6b764 100644
--- a/src/mame/machine/ms7004.cpp
+++ b/src/mame/machine/ms7004.cpp
@@ -104,54 +104,54 @@ bit sig XSn ????n
14 22 4 3
15 23 5 4
-0xc9 KEY_LANGLE_RANGLE 'резервная клавиша'
-0xbc KEY_DELETE ЗБ
-0xbd KEY_RETURN ВК
-0xbf KEY_TILDE '; +'
-0xc4 - 'Ъ'
-0xca - '/ ?'
-0xed KEY_PERIOD 'Ю @'
-0xf1 - '_'
+0xc9 KEY_LANGLE_RANGLE 'резервная клавиша'
+0xbc KEY_DELETE ЗБ
+0xbd KEY_RETURN ВК
+0xbf KEY_TILDE '; +'
+0xc4 - 'Ъ'
+0xca - '/ ?'
+0xed KEY_PERIOD 'Ю @'
+0xf1 - '_'
<...>
-0x56 KEY_F1 СТОП КАДР
-0x57 KEY_F2 ПЕЧАТЬ КАДРА
-0x58 KEY_F3 ПАУЗА
-0x59 KEY_F4 УСТ РЕЖИМА
-0x5a KEY_F5 Ф5
-
-0x64 KEY_F6 ПРЕРЫВ
-0x65 KEY_F7 ПРОДОЛЖ
-0x66 KEY_F8 ОТМЕН
-0x67 KEY_F9 ОСНОВН КАДР
-0x69 KEY_F10 ВЫХОД
-
-0x71 KEY_F11 Ф11 (АР2)
-0x72 KEY_F12 Ф12 (ВШ)
-0x73 KEY_F13 Ф13 (ПС)
-0x74 KEY_F14 ДОП ВАРИАНТ
-
-0x7c KEY_HELP ПМ
-0x7d KEY_MENU ИСП
-
-0x80 KEY_F17 Ф17
-0x81 KEY_F18 Ф18
-0x82 KEY_F19 Ф19
-0x83 KEY_F20 Ф20
-
-0xb0 KEY_LOCK ФКС
-0xae KEY_SHIFT ВР
-0xaf KEY_CTRL СУ
-
-0xb1 KEY_META КМП
-0xb2 - РУС/ЛАТ
-
-0x8a KEY_FIND НТ
-0x8b KEY_INSERT_HERE ВСТ
-0x8c KEY_REMOVE УДАЛ
-0x8d KEY_SELECT ВЫБР
-0x8e KEY_PREV_SCREEN ПРЕД КАДР
-0x8f KEY_NEXT_SCREEN СЛЕД КАДР
+0x56 KEY_F1 СТОП КАДР
+0x57 KEY_F2 ПЕЧАТЬ КАДРА
+0x58 KEY_F3 ПАУЗА
+0x59 KEY_F4 УСТ РЕЖИМА
+0x5a KEY_F5 Ф5
+
+0x64 KEY_F6 ПРЕРЫВ
+0x65 KEY_F7 ПРОДОЛЖ
+0x66 KEY_F8 ОТМЕН
+0x67 KEY_F9 ОСНОВН КАДР
+0x69 KEY_F10 ВЫХОД
+
+0x71 KEY_F11 Ф11 (АР2)
+0x72 KEY_F12 Ф12 (ВШ)
+0x73 KEY_F13 Ф13 (ПС)
+0x74 KEY_F14 ДОП ВАРИАНТ
+
+0x7c KEY_HELP ПМ
+0x7d KEY_MENU ИСП
+
+0x80 KEY_F17 Ф17
+0x81 KEY_F18 Ф18
+0x82 KEY_F19 Ф19
+0x83 KEY_F20 Ф20
+
+0xb0 KEY_LOCK ФКС
+0xae KEY_SHIFT ВР
+0xaf KEY_CTRL СУ
+
+0xb1 KEY_META КМП
+0xb2 - РУС/ЛАТ
+
+0x8a KEY_FIND НТ
+0x8b KEY_INSERT_HERE ВСТ
+0x8c KEY_REMOVE УДАЛ
+0x8d KEY_SELECT ВЫБР
+0x8e KEY_PREV_SCREEN ПРЕД КАДР
+0x8f KEY_NEXT_SCREEN СЛЕД КАДР
nothing sends '@' or '`'
diff --git a/src/mame/machine/namcos2.cpp b/src/mame/machine/namcos2.cpp
index 15f6273d97b..4014dd4bd16 100644
--- a/src/mame/machine/namcos2.cpp
+++ b/src/mame/machine/namcos2.cpp
@@ -85,7 +85,7 @@ void namcos2_state::machine_start()
void namcos2_state::machine_reset()
{
// address_space &space = m_maincpu->space(AS_PROGRAM);
-// address_space &audio_space = m_audiocpu->space(AS_PROGRAM);
+// address_space &audio_space = m_audiocpu->space(AS_PROGRAM);
/* Initialise the bank select in the sound CPU */
m_audiobank->set_entry(0); /* Page in bank 0 */
diff --git a/src/mame/machine/xavix.cpp b/src/mame/machine/xavix.cpp
index ae4acf6a9f3..91dd8c1581e 100644
--- a/src/mame/machine/xavix.cpp
+++ b/src/mame/machine/xavix.cpp
@@ -140,7 +140,7 @@ WRITE8_MEMBER(xavix_state::adc_7b81_w)
READ8_MEMBER(xavix_state::adc_7b81_r)
{
-// has_wamg polls this if interrupt is enabled
+// has_wamg polls this if interrupt is enabled
return machine().rand();
}
@@ -207,7 +207,7 @@ WRITE8_MEMBER(xavix_state::dispctrl_6ff8_w)
}
m_video_ctrl = data & 0x3f;
- // printf("%s: dispctrl_6ff8_w %02x\n", machine().describe_context(), data);
+ // printf("%s: dispctrl_6ff8_w %02x\n", machine().describe_context(), data);
}
diff --git a/src/mame/mame.lst b/src/mame/mame.lst
index 4b64ccb53b0..edeff81f53e 100644
--- a/src/mame/mame.lst
+++ b/src/mame/mame.lst
@@ -1030,7 +1030,8 @@ spacepir // (c) 1992
spacepir_14 // (c) 1992
wsjr // (c) 1991
wsjr_15 // (c) 1991
-zortonbr // (c) 1993 Web Picmatic
+zortonbr // (c) 1994 Web Picmatic
+zortonbr_100 // (c) 1993 Web Picmatic
@source:alien.cpp
alien // (c) 2005 Capcom
@@ -10228,6 +10229,7 @@ sf2ebbl3 // 14/02/1991 (c) 1991 (World, bootleg)
sf2ed // 18/03/1991 (c) 1991 (World)
sf2ee // 28/02/1991 (c) 1991 (World)
sf2em // 29/01/1991 (c) 1991 (World)
+sf2en // 04/02/1991 (c) 1991 (World)
sf2hf // 09/12/1992 (c) 1992 (World)
sf2hfj // 09/12/1992 (c) 1992 (Japan)
sf2hfu // 09/12/1992 (c) 1992 (USA)
@@ -10550,6 +10552,7 @@ ssf2tbh // 05/10/1993 (c) 1993 (Hispanic)
ssf2tbj // 05/10/1993 (c) 1993 (Japan)
ssf2tbj1 // 11/09/1993 (c) 1993 (Japan)
ssf2tbr1 // 11/09/1993 (c) 1993 (World)
+ssf2tbu // 11/09/1993 (c) 1993 (USA)
ssf2th // 23/02/1994 (c) 1994 (Hispanic)
ssf2tu // 23/03/1994 (c) 1994 (USA)
ssf2tur1 // 23/02/1994 (c) 1994 (USA)
@@ -31457,6 +31460,7 @@ peset001 // (c) 1987 IGT - International Game Technology
peset004 // (c) 1987 IGT - International Game Technology
peset012 // (c) 1987 IGT - International Game Technology
peset022 // (c) 1987 IGT - International Game Technology
+peset033 // (c) 1987 IGT - International Game Technology
peset038 // (c) 1987 IGT - International Game Technology
peset100 // (c) 1987 IGT - International Game Technology
peset117 // (c) 1987 IGT - International Game Technology
@@ -35600,7 +35604,10 @@ splash10 // (c) 1992 - Ref 922804
ringball // not a gaelco game but based on splash code
@source:splus.cpp
-spss4240 //
+spset005 // (c) 1993 IGT - International Game Technology
+spset015 // (c) 1993 IGT - International Game Technology
+spset026 // (c) 1996 IGT - International Game Technology
+spss4240 // (c) 1987 IGT - International Game Technology
@source:spoker.cpp
spk306us // (c) 1996 IGS
diff --git a/src/mame/video/cps1.cpp b/src/mame/video/cps1.cpp
index 485aa610a23..d347c1ff645 100644
--- a/src/mame/video/cps1.cpp
+++ b/src/mame/video/cps1.cpp
@@ -98,6 +98,7 @@ Nemo (World 901130) 89624B-3 NM
Nemo (Japan 901120) 89625B-1 NM22B ? ? CPS-B-15 DL-0411-10010
Street Fighter II: The World Warrior (World 910129) 1991 90629B-2 STF29 IOB1 90632C-1 CPS-B-17 DL-0411-10012 C632
+Street Fighter II: The World Warrior (World 910204) 89625B-1 STF29? IOB1 90632C-1 CPS-B-17 DL-0411-10012 C632
Street Fighter II: The World Warrior (World 910214) 90629B-2 STF29 IOB1 90632C-1 CPS-B-17 DL-0411-10012 C632
Street Fighter II: The World Warrior (World 910228) 90629B-3 STF29 IOB2 90632C-1 CPS-B-18 DL-0411-10013 C632B
Street Fighter II: The World Warrior (World 910318) 90629B-3 STF29 IOB1 90632C-1 CPS-B-05 DL-0411-10006 C632
@@ -1476,6 +1477,7 @@ static const struct CPS1config cps1_config_table[]=
{"sf2ed", CPS_B_05, mapper_STF29, 0x36 },
{"sf2ee", CPS_B_18, mapper_STF29, 0x3c },
{"sf2em", CPS_B_17, mapper_STF29, 0x36 },
+ {"sf2en", CPS_B_17, mapper_STF29, 0x36 },
{"sf2ebbl", CPS_B_17, mapper_STF29, 0x36, 0, 0, 1 },
{"sf2ebbl2", CPS_B_17, mapper_STF29, 0x36, 0, 0, 1 },
{"sf2ebbl3", CPS_B_17, mapper_STF29, 0x36, 0, 0, 1 },
diff --git a/src/mame/video/edevices.cpp b/src/mame/video/edevices.cpp
index 2c2c1a6e3fd..205d6a27e52 100644
--- a/src/mame/video/edevices.cpp
+++ b/src/mame/video/edevices.cpp
@@ -1,16 +1,16 @@
// license:BSD-3-Clause
// copyright-holders:Pierpaolo Prazzoli, David Haywood
/*
- Electronic Devices video system
+ Electronic Devices video system
- used by
- stlforce.cpp
- mwarr.cpp
+ used by
+ stlforce.cpp
+ mwarr.cpp
- TODO:
- Check if the sprites are an obvious clone of anything else and split out if neccessary
- Steel Force doesn't use the variable height sprites, does the hardware support them?
- Verify offsets / visible areas / overscan etc. especially text layer as Steel Force ending does not quite fit on screen
+ TODO:
+ Check if the sprites are an obvious clone of anything else and split out if neccessary
+ Steel Force doesn't use the variable height sprites, does the hardware support them?
+ Verify offsets / visible areas / overscan etc. especially text layer as Steel Force ending does not quite fit on screen
*/
@@ -247,15 +247,15 @@ void edevices_device::draw_sprites(screen_device &screen, bitmap_ind16 &bitmap,
}
}
-/*
- m_vidattrram
- 0 tx xscroll (or global x scroll?)
- 1 back yscroll
- 2 mlow yscroll
- 3 mhigh yscroll
- 4 tx yscroll
- 5 ---- ---- ---s tMmB layer enables (s = sprites, t = tx, M = highmid, m = lowmid, B = back)
- 6 ---- ---- ---M -m-B rowscroll enables (B = back, m = lowmid, M = highmid)
+/*
+ m_vidattrram
+ 0 tx xscroll (or global x scroll?)
+ 1 back yscroll
+ 2 mlow yscroll
+ 3 mhigh yscroll
+ 4 tx yscroll
+ 5 ---- ---- ---s tMmB layer enables (s = sprites, t = tx, M = highmid, m = lowmid, B = back)
+ 6 ---- ---- ---M -m-B rowscroll enables (B = back, m = lowmid, M = highmid)
*/
diff --git a/src/mame/video/flkatck.cpp b/src/mame/video/flkatck.cpp
index e90c49c9982..ee92aece1e4 100644
--- a/src/mame/video/flkatck.cpp
+++ b/src/mame/video/flkatck.cpp
@@ -121,7 +121,7 @@ uint32_t flkatck_state::screen_update_flkatck(screen_device &screen, bitmap_ind1
const rectangle &visarea = screen.visible_area();
// TODO: reversed polarity? Hard to say, fwiw Combat School uses this in reverse ...
uint16_t sprite_buffer = (m_k007121->ctrlram_r(3) & 8) * 0x100;
-
+
if (m_flipscreen)
{
clip[0] = visarea;
diff --git a/src/mame/video/k007121.cpp b/src/mame/video/k007121.cpp
index 7714f54d60f..d8519e4a3fc 100644
--- a/src/mame/video/k007121.cpp
+++ b/src/mame/video/k007121.cpp
@@ -244,7 +244,7 @@ void k007121_device::sprites_draw( bitmap_ind16 &bitmap, const rectangle &clipre
static const int x_offset[4] = {0x0,0x1,0x4,0x5};
static const int y_offset[4] = {0x0,0x2,0x8,0xa};
int x,y, ex, ey, flipx, flipy, destx, desty;
-
+
if (attr & 0x01) sx -= 256;
if (sy >= 240) sy -= 256;
@@ -254,7 +254,7 @@ void k007121_device::sprites_draw( bitmap_ind16 &bitmap, const rectangle &clipre
/* Flak Attack doesn't use a lookup PROM, it maps the color code directly */
/* to a palette entry */
- // TODO: check if it's true or callback-ize this one and remove the per-game hack.
+ // TODO: check if it's true or callback-ize this one and remove the per-game hack.
if (is_flakatck)
transparent_mask = 1 << 0;
else
@@ -313,7 +313,7 @@ void k007121_device::sprites_draw( bitmap_ind16 &bitmap, const rectangle &clipre
transparent_mask);
}
}
-
+
source += inc;
}
}
diff --git a/src/mame/video/namco_c355spr.cpp b/src/mame/video/namco_c355spr.cpp
index f93c5c4c1fc..053a9f44561 100644
--- a/src/mame/video/namco_c355spr.cpp
+++ b/src/mame/video/namco_c355spr.cpp
@@ -439,8 +439,8 @@ void namco_c355spr_device::get_sprites()
get_list(1, &m_spriteram[buffer][0x14000/2], &m_spriteram[buffer][0x10000/2]);
}
-template<class _BitmapClass>
-void namco_c355spr_device::draw_sprites(screen_device &screen, _BitmapClass &bitmap, const rectangle &cliprect, int pri)
+template<class BitmapClass>
+void namco_c355spr_device::draw_sprites(screen_device &screen, BitmapClass &bitmap, const rectangle &cliprect, int pri)
{
// int offs = spriteram16[0x18000/2]; /* end-of-sprite-list */
if (pri == 0)
diff --git a/src/mame/video/namco_c355spr.h b/src/mame/video/namco_c355spr.h
index 5d53120488e..5e26345b942 100644
--- a/src/mame/video/namco_c355spr.h
+++ b/src/mame/video/namco_c355spr.h
@@ -72,7 +72,7 @@ private:
void get_single_sprite(const uint16_t *pSource, struct c355_sprite *sprite_ptr);
void get_list(int no, const uint16_t *pSpriteList16, const uint16_t *pSpriteTable);
void get_sprites();
- template<class _BitmapClass> void draw_sprites(screen_device &screen, _BitmapClass &bitmap, const rectangle &cliprect, int pri);
+ template<class BitmapClass> void draw_sprites(screen_device &screen, BitmapClass &bitmap, const rectangle &cliprect, int pri);
struct c355_sprite *m_spritelist[2];
const struct c355_sprite *m_sprite_end[2];
@@ -94,4 +94,3 @@ private:
DECLARE_DEVICE_TYPE(NAMCO_C355SPR, namco_c355spr_device)
#endif // MAME_VIDEO_NAMCO_C355SPR_H
-
diff --git a/src/mame/video/xavix.cpp b/src/mame/video/xavix.cpp
index 860c68b2457..8760a1244d5 100644
--- a/src/mame/video/xavix.cpp
+++ b/src/mame/video/xavix.cpp
@@ -76,7 +76,7 @@ void xavix_state::handle_palette(screen_device &screen, bitmap_ind16 &bitmap, co
uint16_t dat;
dat = ramsh[offs];
dat |= raml[offs] << 8;
-
+
offs++;
int l_raw = (dat & 0x1f00) >> 8;
@@ -578,7 +578,7 @@ void xavix_state::draw_sprites_line(screen_device &screen, bitmap_ind16 &bitmap,
tile += gfxbase;
}
-
+
int bpp = 1;
@@ -591,7 +591,7 @@ void xavix_state::draw_sprites_line(screen_device &screen, bitmap_ind16 &bitmap,
/*
if ((spr_ypos[i] != 0x81) && (spr_ypos[i] != 0x80) && (spr_ypos[i] != 0x00))
{
- LOG("sprite with enable? %02x attr0 %02x attr1 %02x attr3 %02x attr5 %02x attr6 %02x attr7 %02x\n", spr_ypos[i], spr_attr0[i], spr_attr1[i], spr_xpos[i], spr_addr_lo[i], spr_addr_md[i], spr_addr_hi[i] );
+ LOG("sprite with enable? %02x attr0 %02x attr1 %02x attr3 %02x attr5 %02x attr6 %02x attr7 %02x\n", spr_ypos[i], spr_attr0[i], spr_attr1[i], spr_xpos[i], spr_addr_lo[i], spr_addr_md[i], spr_addr_hi[i] );
}
*/
}
@@ -739,7 +739,7 @@ uint32_t xavix_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap,
//int count = 0;
set_data_address(base + base2, 0);
-
+
for (int y = 0; y < 256; y++)
{
for (int x = 0; x < 512; x++)
@@ -831,33 +831,33 @@ WRITE8_MEMBER(xavix_state::tmap1_regs_w)
0x2 pointer to upper tile bits
0x3 Fftt bbb- Ff = flip Y,X
- tt = tile/tilemap size
- b = bpp
- - = unused
+ tt = tile/tilemap size
+ b = bpp
+ - = unused
0x4 scroll
0x5 scroll
0x6 pppp zzzz p = palette
- z = priority
+ z = priority
0x7 e--m mmmm e = enable
- m = mode
+ m = mode
modes are
- ---0 0000 (00) 8-bit addressing (Tile Number)
- ---0 0001 (01) 16-bit addressing (Tile Number) (monster truck, ekara)
- ---0 0010 (02) 16-bit addressing (8-byte alignment Addressing Mode) (boxing)
- ---0 0011 (03) 16-bit addressing (Addressing Mode 2)
- ---0 0100 (04) 24-bit addressing (Addressing Mode 2) (epo_efdx)
+ ---0 0000 (00) 8-bit addressing (Tile Number)
+ ---0 0001 (01) 16-bit addressing (Tile Number) (monster truck, ekara)
+ ---0 0010 (02) 16-bit addressing (8-byte alignment Addressing Mode) (boxing)
+ ---0 0011 (03) 16-bit addressing (Addressing Mode 2)
+ ---0 0100 (04) 24-bit addressing (Addressing Mode 2) (epo_efdx)
- ---0 1000 (08) 8-bit+8 addressing (Tile Number + 8-bit Attribute)
- ---0 1001 (09) 16-bit+8 addressing (Tile Number + 8-bit Attribute) (Taito Nostalgia 2)
- ---0 1010 (0a) 16-bit+8 addressing (8-byte alignment Addressing Mode + 8-bit Attribute) (boxing, Snowboard)
- ---0 1011 (0b) 16-bit+8 addressing (Addressing Mode 2 + 8-bit Attribute)
+ ---0 1000 (08) 8-bit+8 addressing (Tile Number + 8-bit Attribute)
+ ---0 1001 (09) 16-bit+8 addressing (Tile Number + 8-bit Attribute) (Taito Nostalgia 2)
+ ---0 1010 (0a) 16-bit+8 addressing (8-byte alignment Addressing Mode + 8-bit Attribute) (boxing, Snowboard)
+ ---0 1011 (0b) 16-bit+8 addressing (Addressing Mode 2 + 8-bit Attribute)
- ---1 0011 (13) 16-bit addressing (Addressing Mode 2 + Inline Header) (monster truck)
- ---1 0100 (14) 24-bit addressing (Addressing Mode 2 + Inline Header)
+ ---1 0011 (13) 16-bit addressing (Addressing Mode 2 + Inline Header) (monster truck)
+ ---1 0100 (14) 24-bit addressing (Addressing Mode 2 + Inline Header)
*/
@@ -885,16 +885,16 @@ WRITE8_MEMBER(xavix_state::spriteregs_w)
{
LOG("%s: spriteregs_w data %02x\n", machine().describe_context(), data);
/*
- This is similar to Tilemap reg 7 and is used to set the addressing mode for sprite data
+ This is similar to Tilemap reg 7 and is used to set the addressing mode for sprite data
- ---0 -000 (00) 8-bit addressing (Tile Number)
- ---0 -001 (01) 16-bit addressing (Tile Number)
- ---0 -010 (02) 16-bit addressing (8-byte alignment Addressing Mode)
- ---0 -011 (03) 16-bit addressing (Addressing Mode 2)
- ---0 -100 (04) 24-bit addressing (Addressing Mode 2)
+ ---0 -000 (00) 8-bit addressing (Tile Number)
+ ---0 -001 (01) 16-bit addressing (Tile Number)
+ ---0 -010 (02) 16-bit addressing (8-byte alignment Addressing Mode)
+ ---0 -011 (03) 16-bit addressing (Addressing Mode 2)
+ ---0 -100 (04) 24-bit addressing (Addressing Mode 2)
- ---1 -011 (13) 16-bit addressing (Addressing Mode 2 + Inline Header)
- ---1 -100 (14) 24-bit addressing (Addressing Mode 2 + Inline Header)
+ ---1 -011 (13) 16-bit addressing (Addressing Mode 2 + Inline Header)
+ ---1 -100 (14) 24-bit addressing (Addressing Mode 2 + Inline Header)
*/
m_spritereg = data;
}
diff --git a/src/osd/modules/render/d3d/d3dhlsl.cpp b/src/osd/modules/render/d3d/d3dhlsl.cpp
index e2a9bb4bc53..2a91dade834 100644
--- a/src/osd/modules/render/d3d/d3dhlsl.cpp
+++ b/src/osd/modules/render/d3d/d3dhlsl.cpp
@@ -877,7 +877,7 @@ int shaders::create_resources()
focus_effect->add_uniform("Defocus", uniform::UT_VEC2, uniform::CU_FOCUS_SIZE);
- post_effect->add_uniform("ShadowAlpha", uniform::UT_FLOAT, uniform::CU_POST_SHADOW_ALPHA);
+ post_effect->add_uniform("ShadowAlpha", uniform::UT_FLOAT, uniform::CU_POST_SHADOW_ALPHA);
post_effect->add_uniform("ShadowCount", uniform::UT_VEC2, uniform::CU_POST_SHADOW_COUNT);
post_effect->add_uniform("ShadowUV", uniform::UT_VEC2, uniform::CU_POST_SHADOW_UV);
post_effect->add_uniform("ShadowUVOffset", uniform::UT_VEC2, uniform::CU_POST_SHADOW_UV_OFFSET);
@@ -1244,17 +1244,18 @@ int shaders::post_pass(d3d_render_target *rt, int source_index, poly_info *poly,
float screen_offset[2] = { xoffset, yoffset };
rgb_t back_color_rgb = screen->has_palette()
- ? screen->palette().palette()->entry_color(0)
- : rgb_t(0, 0, 0);
+ ? screen->palette().palette()->entry_color(0)
+ : rgb_t(0, 0, 0);
back_color_rgb = apply_color_convolution(back_color_rgb);
float back_color[3] = {
- float(back_color_rgb.r()) / 255.0f,
- float(back_color_rgb.g()) / 255.0f,
- float(back_color_rgb.b()) / 255.0f };
+ float(back_color_rgb.r()) / 255.0f,
+ float(back_color_rgb.g()) / 255.0f,
+ float(back_color_rgb.b()) / 255.0f };
curr_effect = post_effect;
curr_effect->update_uniforms();
- curr_effect->set_texture("ShadowTexture", shadow_texture == nullptr ? nullptr : shadow_texture->get_finaltex()); curr_effect->set_int("ShadowTileMode", options->shadow_mask_tile_mode);
+ curr_effect->set_texture("ShadowTexture", shadow_texture == nullptr ? nullptr : shadow_texture->get_finaltex());
+ curr_effect->set_int("ShadowTileMode", options->shadow_mask_tile_mode);
curr_effect->set_texture("DiffuseTexture", rt->target_texture[next_index]);
curr_effect->set_vector("BackColor", 3, back_color);
curr_effect->set_vector("ScreenScale", 2, screen_scale);
@@ -1298,9 +1299,9 @@ int shaders::downsample_pass(d3d_render_target *rt, int source_index, poly_info
{
curr_effect->set_vector("TargetDims", 2, rt->bloom_dims[bloom_index]);
curr_effect->set_texture("DiffuseTexture",
- bloom_index == 0
- ? rt->source_texture[next_index]
- : rt->bloom_texture[bloom_index - 1]);
+ bloom_index == 0
+ ? rt->source_texture[next_index]
+ : rt->bloom_texture[bloom_index - 1]);
blit(rt->bloom_surface[bloom_index], false, D3DPT_TRIANGLELIST, 0, 2);
}
diff --git a/src/osd/windows/window.cpp b/src/osd/windows/window.cpp
index 119efd3dccd..0c762034e69 100644
--- a/src/osd/windows/window.cpp
+++ b/src/osd/windows/window.cpp
@@ -325,7 +325,7 @@ win_window_info::win_window_info(
m_non_fullscreen_bounds.right = 0;
m_non_fullscreen_bounds.bottom = 0;
m_prescale = video_config.prescale;
- m_index = index;
+ m_index = index;
}
POINT win_window_info::s_saved_cursor_pos = { -1, -1 };
diff --git a/src/tools/unidasm.cpp b/src/tools/unidasm.cpp
index 9be741b2bef..feff5c5e580 100644
--- a/src/tools/unidasm.cpp
+++ b/src/tools/unidasm.cpp
@@ -220,7 +220,7 @@ struct s2650_unidasm_t : s2650_disassembler::config
virtual ~s2650_unidasm_t() override = default;
virtual bool get_z80_mnemonics_mode() const override { return z80_mnemonics; }
} s2650_unidasm;
-
+
// Configuration missing
struct saturn_unidasm_t : saturn_disassembler::config
{