It's really interesting to me the differences and similarities between Atari and NES programming. They both use the same 6502 processor (well, a variation on the same processor -- the Atari's is missing a few address lines, and the NES is missing a BCD mode), clocked at similar speeds (the nes is about 50% faster).
But beyond that, things start to diverge. The most interesting to me is fundamentally where things happen, based on how their video chips work.
On the Atari, the video chip (the TIA) is designed to handle a scanline at a time. Which means that, like I've mentioned before, the whole time your TV is drawing, you spend that time babysitting the process, using all your processing time updating each scanline. Then during vblank (the time the TV is repositioning the electron beam), you get to hurry and do your game logic updates.
On the NES, it's practically the opposite. The video chip (the PPU) is designed to handle a whole frame at a time (GASP!). So during rendering, unless you're doing any fancy effects, you get all that time free to do your game logic updates, while the PPU does its thing in the background. Then during vblank, you hurry to push new data to the PPU so its ready for the next frame.
There's still hurrying involved in the NES -- there can be a lot of data that you want to shove into the PPU (new tiles for scrolling, etc), and not a lot of time to do it (most video data has to passed to the PPU over a janky serial interface, written one byte at a time), but compared to the Atari, I feel like I have EONS of time to work with.
It also helps having more RAM than I know what to do with. The Atari had 128 bytes. The NES has 2048 bytes. (Two whole kilobytes!) It's crazy town.
There's still some challenges. Talking to the PPU is weird, you're limited to only 8 sprites per scanline, mid-screen scrolling (ie if you want to add a status bar) is tricky. But so far, it's a different world.
I started by blogging the process of porting my homebrew game Anguna from the Gameboy Advance to the Nintendo DS. Now, my random thoughts on development and chronicling whatever hobby project catches my fancy.
Tuesday, August 23, 2016
Subscribe to:
Post Comments (Atom)
NES Anguna
Well, I had a little bit of time still, while Frankengraphics is finishing up her game Project Blue, to have a little downtime on Halcyon, s...
-
So I've recently purchased DosBox Turbo , the best (as far as I can find) implementation of DosBox for Android, and have been playing th...
-
When I'm too tired/frustrated to work on my NES game, I've been playing around with ideas for another hobby project that I've he...
-
Well, I had a little bit of time still, while Frankengraphics is finishing up her game Project Blue, to have a little downtime on Halcyon, s...
4 comments:
I guess that's exactly the main difference from 3rd generation consoles onward... and if you still remember it has remained this way on the GBA and DS too. Screen blanking time to update VRAM/OAM etc... and screen draw time (usually a lot more) to do game logic. Phew ;)
Absolutely. It amazes me how different the NES and Atari were, but how similar Nintendo kept its general architecture all the way through the DS.
You might find this video useful, or at least entertaining (if you haven't watched it already): https://www.youtube.com/watch?v=Hvx4xXhZMrU It's not that technical, but it might give you some ideas (even though I think you'll face less problems than with the Atari port).
PD: I've started learning GBA programming to develop a game/POC on the console. Would you mind if I bombarded you with questions from time to time?
Sure, I'm happy to help. You can email me at Nathan Tolbert at gmail
Post a Comment