XaiJu
JOTEGO
JOTEGO

patreon


MCU Time! Bubble Bobble, Tokio, Renegade...

Español abajo

When I made the JTBUBL (Bubble Bobble, Tokio) core, I had  to limit it to certain game versions that used a MCU (Micro Controller  Unit) for which I had found a Verilog module. That meant putting the  original Tokio version aside and working only with the bootleg. The same  happened with Renegade too, where I had to hide the MRA for the  original version and use one for a bootleg instead. Not only that was a  limitation I didn't like. But, I also had no idea whether the MCU module  I was using was cycle accurate.

Come forward to Halloween 2023, I presented JTSHOUSE,  featuring Splatter House support on FPGA. It worked using the same MCU  with some patches as I had discovered several things:

About the same time, LordBarker80, a patron and  proud owner of a Japanese Bubble Bobble board, contacted me about  slowness in the core, compared to his system. Again, the smoking gun was  that MCU implementation.

It was clear that I needed to have my own modules for all  these MCUs (at least four models for now). But my experience designing  CPUs has been a mixed bag. QSound's DSP16 wasn't too bad but the NeoGeo  Pocket CPU was a hard design that got even more complicated when I tried  to work on it with an unexperienced team. Having learnt from that, I  approached the Konami CPU using a mix of 50% microcode, 50% hardware.  That went much better.

Microcoding is a digital design technique were the  sequencing of a state machine (such as a CPU) is encoded in a memory.  The way you describe the entries in the memory has some resemblance to  assembly code, hence the term. Microcoding is more readable, debuggable  and understandable than regular digital logic. Making debugging as less  painful as possible is a design priority for me, after the NGP  experience. So this time I tried a more radical approach:

With these design goals, I wrote my own automation tools  and got three radically different MCU models (MC6801, MC6805 and  HD63701Y0) working in just two weeks. With this approach, all these MCUs  are cycle accurate by construction (even the interrupt service timing  is exact). My tools even print a report of the number of clock ticks  that each processor instruction takes and compare it to the  specification. I have attached images of these reports for the three  devices. Thanks to this new development, we now have support for the  original game versions that relied on an MCU:

New Supported Versions

About the speed discrepancy,  LordBarker80 and I went back and forth testing new core iterations. The  old JTBUBL (version v1.3.2) had a delay of 2.85" after 9'24", or  roughly 85 microseconds/frame. The new version delay is only 30 microseconds/frame.  This is a huge improvement, as we have more than halved the speed  difference. But, I was expecting it to be perfect. I thought the crystal  oscillator in the Bubble Bobble board may have become faster over time  (a phenomenon called aging in the industry). But after measuring a few boards in our lab, aging could only account for 0.02% or some 3  microseconds/frame. So there must be something else going on. Now that I  am confident that the MCU is reliably built, I can double check other  items in the core.

This new approach and tools will be applied to Splatter  House and Double Dragon, fixing the MCU accuracy in both of them. There  are many other games that directly use the same MCUs. Just to mention a  few for which I already have traction on:

I am also going to apply this approach to the NeoGeo Pocket CPU and re-design it from scratch. I think it will be faster and more  enjoyable than to continue debugging the current core. So, yes that core  was on hold while I was looking for a way to tackle the CPU debugging.  This is the approach I needed.

Update to Patreon Tiers

As I announced in October, I have modified the entry-level  tiers for new members. I want to say thanks to long-time supporters by  keeping their tier price fixed. Current members will not see changes to  their tier and price.

Español

Cuando hice el núcleo JTBUBL (Bubble Bobble, Tokio), tuve  que limitarlo a ciertas versiones del juego que utilizaban una MCU  (Micro Controller Unit) para la que había encontrado un módulo Verilog.  Eso significó dejar de lado la versión original de Tokio y trabajar sólo  con la pirata. Lo mismo ocurrió con Renegade, en el que tuve que  ocultar el MRA de la versión original y utilizar en su lugar uno pirata.  No sólo era una limitación que no me gustaba. Además, no tenía ni idea  de si el módulo MCU que utilizaba era preciso para el ciclo.

Llegados a Halloween de 2023, presenté JTSHOUSE, con  soporte para Splatter House en FPGA. Funcionó usando la misma MCU con  algunos parches, ya que había descubierto varias cosas:

Más o menos al mismo tiempo, LordBarker80, un  mecenas y orgulloso propietario de una placa japonesa Bubble Bobble, se  puso en contacto conmigo acerca de la lentitud del núcleo, en  comparación con su sistema. De nuevo, la pistola humeante era la  implementación de la MCU.

Estaba claro que necesitaba tener mis propios módulos para  todas estas MCUs (al menos cuatro modelos por ahora). Pero mi  experiencia diseñando CPUs ha sido una de cal y una de arena. El DSP16  de QSound no fue difícil, pero la CPU de la NeoGeo Pocket era un diseño  muy enrevesado que se complicó aún más cuando intenté trabajar en él con  un equipo sin experiencia. Tras aprender de aquello, abordé la CPU de  Konami utilizando una mezcla de 50% de microcódigo y 50% de hardware.  Eso fue mucho mejor.

El microcódigo es una técnica de diseño digital en la que  la secuencia de una máquina de estados (como una CPU) se codifica en una  memoria. La forma de describir las entradas en la memoria tiene cierto  parecido con el código ensamblador, de ahí el término. La  microcodificación es más legible, depurable y comprensible que la lógica  digital normal. Hacer la depuración lo menos dolorosa posible es una  prioridad de diseño para mí, después de la experiencia con la NGP. Así  que esta vez he intentado un enfoque más radical:

Con estos objetivos de diseño, escribí mis propias  herramientas de automatización y conseguí que tres modelos de MCU  radicalmente diferentes (MC6801, MC6805 y HD63701Y0) funcionaran en sólo  dos semanas. Con este enfoque, todos estos MCU son precisos en cuanto  al ciclo (incluso la temporización del servicio de interrupción es  exacta). Mis herramientas incluso imprimen un informe del número de  pulsaciones de reloj que tarda cada instrucción del procesador y lo  comparan con la especificación. He adjuntado imágenes de estos informes  para los tres dispositivos. Gracias a este nuevo desarrollo, ahora  tenemos soporte para las versiones originales del juego que dependían de  una MCU:

Nuevas versiones soportadas

Acerca de la discrepancia de velocidad,  LordBarker80 y yo probando sucesivas iteraciones del núcleo. El antiguo  JTBUBL (versión v1.3.2) tenía un retardo de 2.85" después de 9'24", o  aproximadamente 85 microsegundos/fotograma. El retardo de la nueva versión es de sólo 30 microsegundos/fotograma.  Es una mejora enorme, ya que hemos reducido a menos de la mitad la  diferencia de velocidad. Pero esperaba que fuera perfecto. Pensé que el  oscilador de cristal de la placa Bubble Bobble podría haberse vuelto más  rápido con el tiempo (un fenómeno llamado envejecimiento en la  industria). Pero después de medir unas cuantas placas en nuestro laboratorio, el envejecimiento sólo podía explicar el 0,02% o  unos 3 microsegundos/fotograma. Así que tiene que haber algo más. Ahora  que estoy seguro de que la MCU está construida de forma fiable, puedo  volver a comprobar otros elementos del núcleo.

Este nuevo enfoque y herramientas se aplicarán a Splatter  House y Double Dragon, arreglando la precisión de la MCU en ambos. Hay  muchos otros juegos que utilizan directamente las mismas MCU. Por  mencionar sólo algunos que estamos mirando:

También voy a aplicar este enfoque a la CPU de NeoGeo Pocket y rediseñarla desde cero. Creo que será más rápido y divertido que  seguir depurando el núcleo actual. Así que, sí, ese núcleo estaba en  espera mientras yo estaba buscando una manera de abordar la depuración  de la CPU. Este es el enfoque que necesitaba.

Actualización de los niveles de Patreon

Como anuncié en octubre, he modificado los niveles de  entrada para los nuevos miembros. Quiero dar las gracias a los que me  apoyan desde hace tiempo manteniendo fijo el precio de su nivel. Los  miembros actuales no verán cambios en su nivel y precio.

MCU Time! Bubble Bobble, Tokio, Renegade... MCU Time! Bubble Bobble, Tokio, Renegade... MCU Time! Bubble Bobble, Tokio, Renegade... MCU Time! Bubble Bobble, Tokio, Renegade...

Comments

the best alternative right now is ms pacman for snes and genesis cores.

Quinterrya Swanson

I've just recently obtained an analogue pocket and subscribed to this patreon page, Are there any cores for the pacman arcade game?

DatGeekUKnow

I too also have this issue, my own version and with online (US and Japan) version

DarkStar7

same result of the crc of the rom 2db1d9a8

Nacho

same issue here. Cores updated with pocket_updater 2.38.0

Nacho

Hi again I checked your answer on Github, so I took the Bubble Bobble MRA file from here : https://github.com/jotego/jtbin/blob/master/mra/Bubble%20Bobble%20(Japan%2C%20Ver%200.1).mra Then the MRA bin (for linux) from here : https://github.com/sebdel/mra-tools-c/tree/master/release/linux Then I did the process again, and I obtained a 786.7kB bublbobl.rom file (CRC32 = 2db1d9a8) And I still got the same issue. So I put back the core from 2023-11-24, and I've got a black screen, nothing happens. I don't understand what I'm doing wrong... EDIT : I'm not very familiar to Discord, I think I need a link or an invitation to join your server

mpatou

Brilliant!

Hiddenbyleaves

Done, on Github

mpatou

Thank you. I actually found and fixed several bugs in the new MCU while connecting it to Double Dragon which could be the cause of the issue you are seeing. Could you please create an issue in GitHub: https://github.com/jotego/jtcores/issues Or upload the snapshots to our Discord server, please?

JOTEGO

Hi I've encountered some graphical issues after having updated Bubble Bobble pocket core : some part of the lower right corner of the background is missing with Bubble Bobble, I have other "misdisplays " when playing Scramble. I took some pictures, is there any way to show them?

mpatou

Great update and nice approach. I’m stoked about the Namco System 1 core getting fixed up and additional games to be added.

Owlnonymous

Thank you very much for all the work you and the team does.

LoBai Zen

When docked, press F2 on an attached keyboard. When used as handheld, press the 1P and the main action button.

JOTEGO

Really appreciate your diligence and focus on accuracy, this is a fascinating update.

Mysterious Benefactor

Thank you!

Dr Tenma

Great work as usual Although, something is missing from almost all arcade cores for the Analogue Pocket : how d we enter the test/service menu (with CPS2 core for example)?

mpatou

I understand about half of it (I'm primarily a firmware guy so I understand how to read schematics, data sheets, can program in assembly, etc.) and the explanation here makes perfect sense as a way to proceed forward. If anything, I think he's understating the magnitude of impact this will have on the community. Reworking several cores to be even closer to perfect is... Huge.

Matthew Caron

Thank you Jotego

John Fletcher

Great efforts from your side, JT, to reproduce our beloved arcade games as they were designed/intended to run!!

Thorias

As always, most impressive. THANK YOU for the level of dedication you bring to this project day in and day out.

Bedwablackburn

Thanks for your efforts JT you are the man! It is much appreciated!

Alexander Vasquez

Big fan of the perfectionism. Crushing it.

Trey S.

Thank you for all your work Jotego!

Mike Chapa

Thank you for the update and for working on this!

Mat Azel

Looking forward to the releases with this new methodology in development and all the chips that will be preserved by it.

Daniel Thomas Stack

Maintenance releases are always great! Thank you for your hard work!

Lukas Schaper

Rolling Thunder!?! OMG

LiteUp X

Man, I love reading this stuff. Even though I know didly squat about the technical work you guys do, it makes me feel like I understand and part of the team. lol.

Dwight Davis

nice work jotego

Baz M

Thanks for sharing these details about your process and the work involved. It’s fun to read and learn about this stuff. Keep up the great work!

Richard Maxey

I really appreciate your perseverance in curating your existing library of cores. Thank you!

joshewah777

Your meticulous dedication to accuracy and preservation is VERY appreciated!!! Great work!

Cory Stargel

Gracias por vuestro trabajo

Fabio Degrassi

Excelente trabajo!!! Gracias por seguir perfeccionando esos nucleos de juegos clásicos!!!

ronalvel .

Yes Rolling Thunder on the horizon! Love to see it, thanks Jotego!

Stephen Marshall

Thanks JT and team, have a good weekend.

Pixel Cherry Ninja

MiSTer users, run update_all to get the new files. MiST/SiDi files in JTBIN.

JOTEGO


More Creators