Tuesday, 26 November 2013

Less hacky

Last night I managed to clean up the linker script and it now builds with multiple ASM files linked together, as opposed to a monolithic source file with .includes scattered throughout.

And today at lunchtime I put together a minimal header include file and linker script for the NGCD.

Have to say, the NeoCD emulator does a better job of rendering the scaled sprites than MAME does. Whether it looks that much better on real hardware - I have no idea. Unfortunately, developing for the NGCD is a more tedious process, as each build requires un-mounting the virtual CD image, burning another with ImageBurn (which I've managed to reduce to a 2-click process) and then re-mounting and launching the emulator. There's also the lack of a built-in debugger, which I've already used in MAME extensively whilst trying to solve my numerous NOOB mistakes, and I haven't even scratched the surface of the port yet!

EDIT: After proof-reading this I realised I could probably leave the image mounted and copy the PRG file directly to the virtual CD drive - DOH!

As a result I will primarily be working on the cart version, which can be up-and-running in MAME well within 2 seconds from the last edit change. Every now-and-then I'll check that I haven't broken the NGCD build.

So now it's down to the business of porting the Z80 code. My first milestone is to have the attract mode screens (minus the game-play demo) ported and cycling through. That's at least a few week's work given my time constraints, so probably not a lot to blog about (except for hardware news) until then.


  1. Nice work! It will be interesting to see whats the minimum hardware/fpga to run neogeo on when its getting to the hardwarestage :) The Aes has a bigger library of games than the ngcd, but the soundtracks are awesome on the cd games.. shame thou many got spriteframes/animations reduced.

    Are you going to work on both cd and cart system simultaneously?

    Whats the requirements for the fpga when you were choosing fpga for this project? Any specific reason for the Altera Cyclone V 5CEA7? Seems to be very expensive and only for sale in developer boards around 1000$?

  2. I didn't originally plan to support NGCD at all, but my recent work with Neo Kong has me thinking that perhaps it would be possible without too many changes? I have some SDRAM on the board already, so perhaps I just need some interface to a CD and/or CD emulator and it'll be almost there? I'll have to think about it.

    I don't think the Neo Geo logic will require a large FPGA. There will be a fair amount of caches though, which are easier to implement in on-chip RAM, so I'm not sure what the final device will be. I do have Joy Joy Kid running with FIX layer graphics on an Altera DE1 though; but having said that, the Neo Geo is one giant sprite engine so perhaps that's not saying much!?!

    Yes, I've chosen the largest FPGA that was available since I'll only make about 1/2 dozen of these boards. It's purely for development & prototyping a large number of designs and the bigger the better - more room for debug logic and SignalTap traces!