What's new

rockets

Student
Joined
Oct 24, 2022
Messages
12
Reaction score
29
Location
CPH
Hi!

I've been thinking about trying to do some homebrew on System 32 together with a friend of mine (Hi @Toonz ! :)

I'm trying to find as much documentation about the hardware as possible, but it seems there is not much around. Does anyone know where to find more info?

Right now, it seems my best bet is to dive into the MAME sources and try to extract info from there..

Thanks
 
I can't answer your question, but this is a great place to ask!

That being said, what cool things are you thinking about?
 
Oh man, I hope I'm wrong but I don't think there's much out there.
MAME is almost certainly going to be the most thorough documentation.
Some custom chips were shared among other pcb families, like io and color mixing.
Sega Retro has a little bit of summary, with linked references including an NEC V60 programmers reference.

If I find anything else I'll post it, it would be cool to see some homebrew especially since there's a multi in the works.
 
@rockets Great to see you in here :) I'm sorry I could not help on the technical side. Luckily this is the place where the masterminds hang out IMO.
So you are in the right place ^^. I'll just sit on the sideline and play with my simple toys and let the big boys talk tech. Cheers.
 
The problem with MAME is that it just emulates enough to get the games running - some odd things like DMA setups or register/interrupt acknowledgment that will be required on real hardware will be missing. So I guess the best approach is to try and get the simplest "hello world" going in MAME, and then trying to run that on real hardware.

It'll be interesting to see! I've got a Sega System 16B and it would be fun to make a simple game for it... but I have too many projects already, and I need to make some progress before starting anything new...
 
I'll admit that going with system 32 instead of system 16B was/is my fault. I love giant sprites and love what the 32 system can do with them. Luckily I have a few of each, so we are set on HW to test on. Time will tell how far we get. But no matter what I am enjoying the ride.
 
Hi!

Thanks @ekorz - some interesting tidbits in that MAME link.

I've already dived into V60 docs - quite an interesting CPU I must say. When @Toonz first talked about going for System32 I thought it was just another 68000-based machine :) Would have been a lot easier though since there are also 0 tools for NEC V60. Just more of a challenge I guess.

@Fluffy, yeah the HW can probably do more than what has been used in games so far. Maybe something can be discovered by looking at which bits are being used from the various HW registers - any unused bits might unlock unknown features.

Anyway here is my battle-plan:
  1. Look at some system32 games in MAME and get familiar with the debugger
  2. Grab MAME sources and add "support" for my new homebrew game (just copy-paste some other game)
  3. Do the simplest code example (ex. just incrementing a register in a loop). This has to be done straight in machine code since I don't have an assembler or anything
  4. Get that small case to run in MAME
  5. Write an assembler
  6. Try to get some sprites on screen..
  7. Profit!
And of course dive into MAME sources to extract memory maps, HW registers etc..
 
Do the simplest code example (ex. just incrementing a register in a loop). This has to be done straight in machine code since I don't have an assembler or anything
I was going to say "don't forget to kick the watchdog" but then I couldn't find one on the memory map! Maybe someone out there will stumble upon a dev kit or something. I wonder if there's anything already archived somewhere, maybe just in Japanese.
 
Yeah I've been wondering about an LLVM backend too.. I've always wanted to something with LLVM - maybe now is the time :) The key for good code on the V60 is to utilize all the funky addressing modes I think. How that is done could be quite interesting actually.
 
I was going to say "don't forget to kick the watchdog" but then I couldn't find one on the memory map! Maybe someone out there will stumble upon a dev kit or something. I wonder if there's anything already archived somewhere, maybe just in Japanese.
That may be relatively easy to extract if you run the game with MAME's log enabled. (I wish there was a good way to import a log like that into Ghidra, to automatically mark executable code and data access patterns... but then again Ghidra doesn't support V60 either.)
 
Yeah this is good stuff! Thanks!

Think I've seen it before many years ago, but was just unable to find it again :-/

I'll start reading :)
 
@brizzo oh wow! NEC V60 support was added earlier this year! Crazy. Looks good. Found some small issues but was able to fix them a little. Reaching out to the author to get things fixed proper.

Will be checking unidasm out for sure.

I played around with the MAME debugger the other day and it's quite cool - you can view the HW registers with the memory viewer and you can play around with the bits there and see results immediately even though the game is halted!
 
A small status update for you all!

Since I've got an assembler from elsewhere I saved a lot of time so I've basically done step 1-5 done now! I just got hack-rom working running some simple code!

Now I need to do a little more setup code - ex interrupts etc. I've looked at a couple of games and they seem to do more or less the same thing, so I'm gonna copy that. When that is done I will try to get something on screen.

Here is an action-shot from the MAME debugger :) I just fill the main RAM with an increasing value..

1668623825875.png
 
Next stop… Will it run Doom?!
I guess it depend on if there is a plain frame buffer. Judging by the other games it looks like the sprite engine goes a long way, so you may be able to get something similar. Though I am not sure if you can use Doom levels directly.
 
I guess it depend on if there is a plain frame buffer. Judging by the other games it looks like the sprite engine goes a long way, so you may be able to get something similar. Though I am not sure if you can use Doom levels directly.
It does have a plain frame buffer, but it's a bit weird as far as I can see.. there is not enough memory to double buffer so animating stuff will be difficult..
 
Back
Top