mamedev / mame

MAME
https://www.mamedev.org/
Other
8.22k stars 2.02k forks source link

circus charlie (arcade): sprites shown one frame in advanced #12686

Open jotego opened 2 months ago

jotego commented 2 months ago

MAME version

0.268

System information

N/A

INI configuration details

N/A

Emulated system/software

circus charlie

Incorrect behaviour

sprites are directly displayed off sprite memory, bypassing the frame buffer present on the real board.

Although MAME driver captures the existence of a m_spritebank, it is not interpreting it correctly. The CPU selects which part of the sprite memory will be rendered to the frame buffer.

This is the schematic region where the 64 kByte frame buffer is visible. Notice the complex 4-input multiplexer driving it. The top signal is 1V*, which toggles every frame as the name suggests.

image

This is probably a trivial change in the driver, but it goes beyond my skill. Let me collaborate by simply reporting it.

Expected behaviour

Sprite data should be buffered one frame before rendered

Steps to reproduce

normally run the driver

Additional details

No response

ajrhacker commented 2 months ago

1V* would toggle every scanline, not every frame.

jotego commented 2 months ago

You are absolutely right. The 256V signal below that one toggles every frame.

angelosa commented 2 months ago

Driver has no video timing hooked up, do you have that information? Don't think buffered_spriteram will work as intended without that as well.

ajrhacker commented 2 months ago

Circus Charlie, like most Konami games of this era, used an ASIC to generate the H/V timing chain. I don't know the actual timings here, but suspect them to be once again similar to Galaxian/Scramble (16 kHz horizontal, 60.60606 Hz vertical).

jotego commented 2 months ago

It is like Kicker and the others. These are direct measurements off the PCB.

Horizontal period hs Vertical period vs

Frame rate is 60.58Hz, the oscilloscope does not show the second digit.