Changes:
- Re-fixed RSP single-step activation behavior
- Reading the RSP PC returns only the least significant 12 bits
- Fixed flag behavior when read out via CFC2
Oh God, why Nintendo, why? Why make the RSP immediately stop when the main CPU sets single-stepping, but have the RSP execute one instruction before entering single-stepping mode when it sets it on itself? "You manaics! Damn you! God damn you all to hell!"
Changes:
- Initialize RSP registers to 0 in lieu of mame_rand
- Re-fix RSP single-stepping mode when set by a CPU other than the RSP
* 8085 has an internal clock divider by 2. Changed i8085.c to reflect this for I8085. I8080 still at 1.
Games using I8085:
* Changed clock to reflect internal clock divider now in i8085.c
* Added some FIXME: comments where clocks for I8085 are outside specs
Also note that there is no analog sound. Apparently the sound is similar to the regular Space Invaders sounds. The Guru has the board out and hooked up if anyone wants to take a stab at getting the sounds going in this game.
Back to fixing some bugs...
Quite possibly the most useless RSP change I'll ever make, given that no game should ever be affected by these changes. But, eh, accuracy. Apparently only the accumulator registers are initialized to a non-random value on power-on, and apparently the RSP executes exactly one instruction before kicking over into single-step mode when it's set in the status register.
- Fixed accumulator state on powerup by testing against real hardware
- Fixed single-step behavior by testing against real hardware
Added new clone "Player's Edge Plus (XMP00006) Multi-Poker"
Increased DUART memory size
Minor white space clean up & commented the rom defs with game names.
The system 10 & 12 clock speeds have been raised as they run on an upgraded chipset.
All clocks are currently set to divide by 2 externally, I don't know if this is correct.
The clock is also divided internally as we have no wait states, incorrect dma timing, no gpu timing, no dma bus stealing and no gte timing.
Subject: fix for cocktail0119yel
Credit should go to Robbert.
"frogger.c, amidar.c, scramble.camidar.c, frogger.c (all sets),
galaxian.c (froggs at least), scramble.c (scramble+many sets): When it is player
2's turn and the screen is flipped it is offset so that the scores sit in
the middle of the screen."
--
Subject: fix for tokisens0122u3gra
"system1.c tokisens: demo sounds on/off dip swapped around."
Subject: Fixed DBREED72 crash in 0.122u5
Hello. This patch fixes the crash of DBREED72 in m72.c driver caused by
two lines mistakenly removed during the last 0.122u5 update.
Subject: [patch] Fix megaplay.c0122u4red
This fixes the crash reported as megaplay.c0122u4red. The driver
doesn't map the offset into the correct range for the handler. -bios 1
still shows corrupt graphics, but at least it doesn't crash anymore.
Subject: fix for rollerg0111u5gra
"rollerg.c rollerg: coin 3 should be changed to service."
--
Subject: fix for bionicc0109ora.diff
"bionicc.c About the todo list in bionicc.c:
Mame behaves exactly like the pcb, so those are not bugs."
Changed comments in source accordingly.
--
Subject: fix for lcasino0111ora.diff
"ltcasino.c I believe there was no Little Casino 2, but only Little
Casino. Digital Controls re-used Little Casino title even though later versions
of Little Casino might have appeared differently.
It should be Little Casino (older) and Little Casino (newer) to reflect
game differences with Little Casino (older) being an older version clone of
Little Casino (newer) which would be latest revision."
Changed name to Little Casino (older) and Little Casino (newer), also
renamed set ltcasin2 to ltcasinn.
Verified and changed cpu frequencies and oki m6295 pin 7 on the
following pcbs:
Asuka&Asuka, Cadash, Equites h/w games and sound board, F1GP, Super
Formula, Gladiator, Ping Pong king, Great Swordsman, Irem m52 sound
board, Tropical Angel, Explosive Breakers, Magical Crystal, Mad Gear,
Roller Aces, Chinese Hero, Simpsons, Golfing Greats, Time Pilot 84.
Updated Xtal.h to use new OSC values found on Great swordman, Gladiator
h/w and Equites sound board.
Updated informations in Equites.c for the sound board
- Removed videoram_w, colorram_w and spriteram_w and changed all drivers using it to access RAM directly. Still kept the _r function as some old style drivers are relying on them for mirroring support. Will investigate and address those next
Updated all CPU cores to return a CPUINFO_INT_CLOCK_MULTIPLIER of 1.
Changed the core to actually respect both CPUINFO_INT_CLOCK_MULTIPLIER and CPUINFO_INT_CLOCK_DIVIDER.
Updated a number of drivers to use cpunum_get_clock() instead of Machine->drv->cpu[x].clock.
***** Raw input clock speeds should now be specified for all CPUs in the MACHINE_DRIVER. *****
Removed explicit divisors from all drivers using the following CPU types,
which were already specifying non-1 values for CPUINFO_INT_CLOCK_DIVIDER:
* COP4x0
* I8039/8048 families
* M68(7)05, HD63705
* M6809E
* PIC16C5X
* TMS32010
* TMS340x0
In a few cases, it appears that the divisor was not being used, so I guessed in those cases whether or not
the specified clock speed was raw.
changes P3 & P4 Start of Grand Striker 2 to itp_unknown
as there is no P3 & P4 start buttons.
This addresses gstrik20105u4gra however there are several
games that map the service key twice through out the
driver so it's not really "fixed" as far as that's
concerned
* added equivalence circuit for Sanyo EZV audio amplifier
* Set DK_C159 = 0 to avoid over-aggressive high-pass filter. Solely based on observations.
* added comment on above to source
* Added define DK_NO_FILTERS to turn of DAC filters and post-mixer filters for debugging
"armwrest: Subsequent bonus rounds (After rounds 5 and 9) are unplayable because of missing money bag sprite."
the other part of the bug report is out of date, the screenshot doesn't match MAME's current behavior. The finger still appears cut off, but this is intentional. I suspect the bag placement is still slightly incorrect and that it's meant to look like the finger is hidden inside the bag material.
I think further improvements would require studying the actual board / schematics to improve the zoom emulation.
- Targ now uses loaded PROM instead of hardcoded one
- Renamed Side Trak to Side Track as per the title screen
- Removed audio/berzerk.c from make file
- Fixed collision detection but I introduced in video/exidy.c
src/mame/audio/berzerk.c
- Added sh_reset
src/mame/audio/exidy.c
src/mame/includes/exidy.h
- Added reset functionality
- Moved Victory hardware routines here
src/mame/drivers/victory.c
- Some clean-up, mirrored memory map for audio CPU
src/mame/video/victory.c
- Simplified code by removing complicated
dirty tracking. Now VIDEO_UPDATE is
called on every frame, further simplifing
code
src/mame/drivers/exidy.c
- Mirrored memory map for audio CPU
- Added sh_reset
src/emu/machine/6821pia.c
src/emu/machine/6821pia.h
- Added orthogonal accessors
- Removed hacky update_shared_irq_handler(), now the same
IRQ callback maybe called multiple times, but this shouldn't
be a problem
- IRQ lines are cleared on a reset
src/emu/sound/tms5220.c
- Disabled code that set the Buffer Empty flag after a stop
frame. This fixes Victory. This might be the incorrect fix
but the old code wasn't working either.
Cleaned up jaguar driver:
* proper video timing, configured by the chipset
* 32-bit rendering, removing 16bpp hacks
* support for borders
* proper object processor timing, including multiple passes per line
* added R3041 as a clone of the R3000
* fixed XTALs based on documentation
* fixed movd instructions
* add MB8884 and M58715 cpu types
* moved timer hack to M58715
* added ram_mask for internal ram access
* added R.A11 as 'M' to dasm flags
* added EA "IO" port
* mario now uses M58715 as sound cpu
diff + romset for Geebee (F.lli Bertolino license)
The dump comes from an original board marked Namco on the component
side, and F.lli Bertonlino on the solder side.
pics of the pcb: http://www.citylan.it/lista.php?id=629
F.lli Bertolino was the importer of Atari and Namco games in Italy in
end 70s early 80s
Here's a patch that fixes compile errors when compiling a C++ source file including "render.h"
and "palette.h". C++ (at least g++) does not like typedef's for an enum coming before the actual enum.
While investigating alternate gfx layout schemes, I stumbled across
the fact that some drivers are allocating graphics with one layout and
then decoding them with another (!). There's no guarantee this will
work, but for the drivers that do so (all Konami games), the layouts
are similar enough that it does. A related potential bug is that many
drivers are decoding using the layout provided to allocgfx, not the
layout attached the element returned from allocgfx. If the element
had scaling applied to it, this would be incorrect, but since scaling
is rare these are also benign. It would also be a problem if the
layout data had a different internal representation (which is
something I'm experimenting with), so to reduce the possibility of
coding errors and allow for future changes, I'd like to remove the
layout parameter from decodechar.
So here's two patches, the first fixes the affected Konami drivers to
allocate and decode using the same layouts. It changes the notion of
plane_order and bpp in the functions somewhat to let the start
routines select the appropriate layout, but acceptably so IMHO (I can
clean this up further if there are loud objections). The second patch
then removes the layout parameter from all the decodechar() calls.
I also reviewed MESS to see if it had similar problems and didn't find
any.
Reversed ROM set names of Cuebrick World and Japan versions
Changed some function names to reflect parent set
cuebrckj0102u5gre doesn't happen (I didn't fix it)
- added MESS PC-Engine emulatation
- added Blazing Lazers (working)
- added Paranoia (non-working due to lack of jamma interface
emulation)
- fixed MAME debug build under VC2003
Please co-credit Charles MacDonald & Mr. Do for Blazing Lazers.
Note to Nathan: video/vdc.* re taken as-is from MESS, for the
machine stuff I extracted common code (to be shared by MAME and
MESS) and created machine/pcecommn.*
Changed both games to use identical video timing parameters based on measurements of darwin.
Guessed based on available information at the master clock and derived all game clocks from it.
Changed and verified frequencies on Ikari Warriors h/w, Tnk3, Hyper Sports, Jackal and S.A.R
Updated xtal.h to support the 13.4mhz crystal found on Ikari warriors and TNK3 h/w
Verified and corrected a lot of frequencies and oki6295 pin 7 on pcbs:
Double Dribble, Chequered Flag, Diet gogo, Boulderdash, Sly Spy, Psycho
Nics Oscar, Captain Silver, Magical Cat Adventure, Raiden, Superman,
Twin Hawk, Vimana, Ghox, Dogyunn, truxton2, Pipi and Bibis, Fix Eight
and Money Money
They were all verified with frequency counter, even the strangest ones
are right.
* discrete sound
* hooked up z80dma
* combined memory maps
* statics in mario_state struct
* fixed save state issues
* combine sh_* writes into one routine
The skid sound is different from the samples. Reducing the LS123 capacitor by 40% will give the same sound, so I assume this is due to capacitor aging on the board the samples were recorded.
Added code to debug 64-bit builds to allocate all address space below 4GB to help find 64-bit errors.
Added environment variable OSDDEBUGMALLOC which, if set, explicitly overrides the debug malloc debug settings.
Added environment variable OSDDEBUG4GB which, if set, explicitly overrides the new 64-bit address space allocations.
(Sadly this is necessary due to my nvidia D3D drivers being 64-bit unclean....)
Cleaned up atarijsa memory maps.
Added save state support to atarirle, and cleaned it up a bit.
Added save state support to atarig1 driver.
Fixed pitfight0109u2gre
Added talkback to narc sound boards and wired it up to the Z-unit board.
Connected Y-unit reset for various sound boards.
Added sound IRQ state detect to ADPCM board and wired it up to the Y-unit board.
Verified and documented XTALs on the Williams sound boards and Y/Z-unit PCBs.
SGI are bastards who use a 9-bit-byte framebuffer, use the extra bits to store pixel coverage, and can use the coverage bits for pixel alpha. This wont' be implemented for a good long while.
* fixes ad2083_0111u5gra - adds cocktail switch
Note: The bug report mentions "And player 2 control is not hooked up in cocktail mode."
The game will use player 1 inputs even in cocktail mode. Probably never designed for cocktail operation
* fixes skychut37b1yel
* fixes skychut37b6gre
* adds samples to ipm invaders - just rename your old invaders samples to ipminvad to test
* added - amongst others - "capsule" dip switch to ipm invaders
* sound ports identified
* demo sound and cabinet type driver configuration
* more I don't remember
- Move texture masking to occur after coordinate adjustment
- Fix 32-bit texturing in load_tile (Mario Kart 64 title screen)
- Add zero-alpha early-out (Mario 64 trees/stars, Mario Kart 64 trees/karts)
Removed hack in setting the timer in the MIPS core, which caused missed timers on the aleck64 games.
Fixed icount management in the RSP core which caused it to report negative cycle counts.
Fixes aleck64_0120red and mtetrisc0115u1red.
Added XTAL defines to bfm_sc2.c
There is also a small style cleanup for lvcards.c to remove the AGEMAME
reference which is now invalid.
I would have done the same XTAL definition for MPU4, but despite the
schematics claiming a 6.88MHz
crystal, I hven't actually had a PCB in my hands to check, and it's not
on either of the two lists in xtal.h, so I'm leaving it be.
This patch fixes the following issue in the 6522 emulation:
- When writing to the ACR register with the timer 1 in continuous
counting mode, the timer 1 value should not be reloaded but keep on
counting.
This fixes the winwork.c and poly(new).c meory leaks in the viper.c
driver. I didn't look at the x86drc.c, because Aaron said it will be
changed soon and there is no need to investigate those leaks at all.
As I wanted to update my own personal TODO about that fix I
recognised it only happens in viper.c as well, so I took a stab at
it. It was just anothe rmissing cleanup function and I also cleaned
up the *_exit() potions/usage of the cores supporting DRC a bit.
0. This patch does minor cleanup to existing layouts, trimming/padding
entries as appropriate and reformating a few layouts.
1. This patch introduces a GFXLAYOUT_RAW() macro, and uses it
throughout. It codifies the requirements for a raw layout in one
place.
2. This patch adds new validation code to the core for some previously
unchecked assumptions about layouts, and reduces the number of
references to the gfx_layout fields in preparation for a change in the
representation.
3. This patch constifies the remaining non-const gfx_layouts in MAME.
It does this by adjusting the code so that the only modification to a
layout ever needed is for the total field, which is then handled by
modifying a stack-based copy of the layout before invoking allocgfx. I
also spent some time consolidating and simplifying the layout code in
konamiic.c.
- removed years from copyright notices
- removed redundant (c) from copyright notices
- updated "the MAME Team" to be "Nicola Salmoria and the MAME Team"
* completed tms5110A code
* working speech synthesis
* documented analysis done on pcb pictures and findings
* as a consequence, marked all sound roms as BAD DUMP
* created sound driver in scramble.c
Added save state support to YM2413.
Modified slapstic code to support address range mirrors.
Cleaned up Rampart driver:
- simplified rendering code
- full memory map
- added save state
beastrzb097u2red.patch
- added GAME_NOT_WORKING flag, so this bogus bug report can be
removed (not even worth 1 buck!)
20080104_1.patch
- fixes a memory in src/mame/machine/stvcd.c
memoryleak0118u1ora.patch
- fixes a memory leak, that only happened when no RawInput API was
available
memory_leak0111u6ora_1.patch
- only a partial patch - model3.c still missing
midzeus.c driver
Renames game rom from invasn to invasnab & invasnv4
title changed to "Invasion - The Abductors (version 5.0)"
added version number to other games.
added notes about the latest software level as per
the Midway service bulletin
This fixes namcos1_0118u2yel, and
does a little tidying of the namcos1.c files as well. There may still
be some additional variables to reset, but this was enough to fix the
bug as reported.
* XTAL-based timing
* Correct video timing
* Full memory map
* Correct memory usage ("zero page" RAM is shared with videoram)
* Removed all input hacks
* Fixed interrupt generation
* Connected coin counters
* Added save state support
Also fixed incorrect dependency in cdrom.c.
This is an updated version of my earlier ATTR_PRINTF patch. It was
reviewed by Atari Ace to use ATTR_PRINTF properly and fixes even more
format errors. I also reviewed the whole source again and it is now
used in all possible places.
Removed ui_popup(). Drivers should always be using popmessage() instead (has been this way for a while).
Augmented popmessage() so that you can pass NULL to immediately dismiss any messages.
* fixed interrupt handling
* added support for edge-triggered interrupts on '32
* expanded interrupt support for the '32
* updated drivers using TMS3203x core to deassert interrupts
* added externally accessible functions for converting '3x floating point format
* updated gaelco3d driver to use new functions
Zeus2 (+related) updates:
* fixed save states for DCS games
* cleaned up Zeus2 waveram handling
* added Zeus2 save state support
* added preliminary model and quad rendering support for Zeus2
* added support to timekpr for the ZPRAM used on Zeus2
* hooked up ZPRAM in Zeus2 games
* hooked up controls in Zeus2 games
* updated poly.c to ensure it is idle before saving state
- fixed mario0110u1gre
- rewrote driver, separate MACHINE_DRIVER(mario_audio)
- palette from schematics
- video timing from schematics
- driver configuration switch Nintendo/Std Monitor
- got rid of COLORTABLE
- clocks as defines in .h
- use XTAL_*
edrandy0113gra
robocop2_0106u3gra
Converts 2 common ports to macros
Uses port_include & port_modify where needed
Added dip locations
Added DSW3 for Robocop2 (thanks to Byran McPhail)
The attached patch adjusts most conditional logging in MAME to use the
idiom "do { if (VERBOSE) logerror x; } while (0)". This has the
benefit that the compiler checks the syntax of the logging even in the
case it will be eliminated, and in fact a number of cases here needed
adjustments to compile because of this.
Here is a fix I've done to the Z80 CPU core that removes the increasing
of the R register from each IX/IY related (FD xx or DD xx) instruction.
This corrects the amount the R register should increased to to 2,
instead of 3. Documentation I've read suggests that the R register is
increased by 1 for each instruction with no prefix, and by 2 for each
instruction with a prefix (DD, FD, ED, CB, DD CB and FD CB). This fixes
some protected cassette loaders in the MESS Amstrad CPC driver, and
maybe others, which require the R register to be correct for the next
routine to be decoded correctly. I'd doubt that there is much, if any,
noticeable impact for MAME, as the R register is really only useful to a
program as a simple random number generator (or seed).
I've tested the fix with Pacman, in MAME, and when it comes across a LD
IX,xxxx or ADD IX,xx it will increase R by 2, whereas previously, it
increased R by 3.
Added artifical Z offset of -2 to make the full screen show in crusnexo.
Really fixed TMS3203x interrupt handling.
Added hack to catch invalid SP values during 32031 execution (debug mode only).
Corrected rom name for Thundercade
changed clocks to OSC by divider IE:
16000000/2 /* 8MHz */
Changed Orbs clock to 16MHz with note about 14.xx MHz
Changed Meta Fox's x0-006 (65c02) to same as Thundercade
Changed the YM3438 in Ultra Toukond Densetsu from 6MHz
to 1600000/4 /* 4MHz */ as there is no mention of 6MHz
OSC on PCB
* fixed interrupt handling
* added support for edge-triggered interrupts on '32
* expanded interrupt support for the '32
* updated drivers using TMS3203x core to deassert interrupts
* added externally accessible functions for converting '3x floating point format
* updated gaelco3d driver to use new functions
Zeus2 (+related) updates:
* fixed save states for DCS games
* cleaned up Zeus2 waveram handling
* added Zeus2 save state support
* added preliminary model and quad rendering support for Zeus2
* added support to timekpr for the ZPRAM used on Zeus2
* hooked up ZPRAM in Zeus2 games
* hooked up controls in Zeus2 games
* updated poly.c to ensure it is idle before saving state
This patch should complete the addition of static qualifiers to all
MAME symbols that aren't explicitly exported. It primarily handles
generated code (e.g. amspdwy.c), plus a handful of cases I'd
previously missed and some new cases introduced in the last update.
One interesting bit was the discovery that the 32-bit scanline
routines in drawgfx.c are unused. I debated eliminating them but
decided instead to just export them. Various internal drawgfx
functions were conditionally removed by examining a new RAW define,
although one routine (blockmove_8toN_alphaone) was determined to be
dead code.
While investigating constifying MESS, I came across a few core APIs
that were missing const qualifiers which this patch fixes. I also
consted up tx1.c while I was at it.
- cvs games: according to PCBInfos speech chip is TMS5100.
Changed driver to use TMS5100 and "game system operational" now sounds more natural
- removed sound/m58817.*
- added support for multiple coefficients maps to tms5110.*
- added coefficient maps for TMS5100 and M58817 from documented sources to tms5110r.c
- fixed interpolation factors (see tms5110r.c for reason)
- made lattice calculation precision 9bit
- added support for READBIT and LOADADDRESS commands to tms5110.c
- more changes in line with various patents
Note: Protection still not understood in detail. Driver only contains "hacks" as workarounds. Consequently, more protection issues are likely to surface in the future.
Besides confirming clocks on some games, I modified:
Aerofighters and Turbo Force sound z80 to 5mhz
Midnight Resitance 68k cpu to 10mhz (20mhz crystal) and modified m6295
clock to 1mhz. Also confirmed pin 7 is high.
Midnight resistance has a lot of slow downs on the pcb too
This small patch makes some minor "code quality" improvements to MAME.
First off, some remaing static/const qualifier missed cases were
addressed. Secondly, a few cases of missing #include "foo.h" were
added. Thirdly, a few global names were modified to make them less
generic/more consistent (voodoo.c, vrender0.c, lethal.c, rungun.c,
zac2650.c). Fourthly, some dead/useless code was removed
(i8051.c,model1.c,romcmp.c).
Verified some cpu clocks of original boards using a frequency counter:
* Changed Success Joe Ym2203 clock from 3mhz to 4mhz
* Changed Pang M6295 clock from 990khz to 1Mhz
* Changed Halley Comet main cpu clock to 1.664mhz (it's not a mistake, the clock is very low)
* Cleaned up zeus wave RAM accessors.
* Changed rendering code to allow for greater parallelism on multicore systems.
* Removed some vestigial zeus 2 hacks.
* Reduced visible area to remove artifacts.
* Made right/bottom vertices inclusive to fix some gapping issues.
* Fixed invasn lightgun offset.
* Marked invasn as playable.
Zeus 2 hardware:
* Fixed ROM loading, added banking support.
* Separated zeus 2 video implementation from zeus implementation.
* Implemented direct pixel accesses; enough to get startup screens to show.
ADSP-2100:
* Properly documented ADSP-2104 internal memory map.
Removed many hacks from both.
A couple of games changed status from GAME_NOT_WORKING to fully playable:
stagger1, redhawk, redhawkb, grdnstrm, spec2k, firehawk (all - former afega.c)
and tharrier/tharrierj(nmk16.c)
invasn looks a lot better now.
Extracted data for lights.
Added backface culling which mostly works but fails sometimes, so it is disabled.
Started on some initial lighting calculations.