SNES Newbie
Moderator: Moderators
Forum rules
- For making cartridges of your Super NES games, see Reproduction.
SNES Newbie
Hello!
I have recently taken an interest in programming for the SNES, and I've gotten to know the basics of the console's architecture.
I've messed with sprites, backgrounds, tile collision, and simple horizontal-DMA effects, but I feel like I don't know enough to advance further into a large project for the console. (I actually made a few small projects for SNES with PVSNESLib years ago but I had no idea how the console worked since you work with a higher level language and I didn't bother looking at any documentation at the time.)
Here's a video I made showcasing what I've been messing around with using the WLA-DX cross assembler and I'm quite happy with its progress so far. (Of course, the code needs some cleaning up. )
https://www.youtube.com/watch?v=ttLVtmIrmyo
I'd like to know more about what things are, the terminologies behind them, and how they work; Great example is "metasprite". I've heard this term quite a few times while lurking around here on the forums and I'm not sure what it is. I know the general purpose of OAM and how there's a low and high table (512 bytes for low and 32 for high?) but never heard of metasprites until visiting the forum.
I Think I understand GP-DMA well enough to utilize it for simple tasks like transferring, let's say, a tile into VRAM.
SPC700 is by far the most complicated thing I'm having trouble understanding, and will definitely need a few pointers to guide me in the right direction.
Responses and resources are definitely appreciated!
I have recently taken an interest in programming for the SNES, and I've gotten to know the basics of the console's architecture.
I've messed with sprites, backgrounds, tile collision, and simple horizontal-DMA effects, but I feel like I don't know enough to advance further into a large project for the console. (I actually made a few small projects for SNES with PVSNESLib years ago but I had no idea how the console worked since you work with a higher level language and I didn't bother looking at any documentation at the time.)
Here's a video I made showcasing what I've been messing around with using the WLA-DX cross assembler and I'm quite happy with its progress so far. (Of course, the code needs some cleaning up. )
https://www.youtube.com/watch?v=ttLVtmIrmyo
I'd like to know more about what things are, the terminologies behind them, and how they work; Great example is "metasprite". I've heard this term quite a few times while lurking around here on the forums and I'm not sure what it is. I know the general purpose of OAM and how there's a low and high table (512 bytes for low and 32 for high?) but never heard of metasprites until visiting the forum.
I Think I understand GP-DMA well enough to utilize it for simple tasks like transferring, let's say, a tile into VRAM.
SPC700 is by far the most complicated thing I'm having trouble understanding, and will definitely need a few pointers to guide me in the right direction.
Responses and resources are definitely appreciated!
Re: SNES Newbie
"Metasprite" means a single cel of animation made out of multiple entries in the OAM. For example, in Super Mario World, Mario's cels are roughly 16x32 pixels in size made of two 16x16 pixel sprites. Sprites in a metasprite need not be aligned corner-to-corner; Yoshi's, for instance, are offset somewhat to put his head forward of his body.
For SPC700, when starting, you'll want to use a third-party engine. Right now, the most complete engine available for homebrew is probably SNES GSS.
For SPC700, when starting, you'll want to use a third-party engine. Right now, the most complete engine available for homebrew is probably SNES GSS.
Re: SNES Newbie
A metasprite is not a hardware thing, but a common concept in game programming.
It's basically a sprite made out of multiple smaller hardware sprites. So one way to define a metasprite is with a bunch of data that your code knows how to interpret when writing to the sprite buffer.
Similar terminology is used with metasprites = a collection of smaller sprites, and a common way to compress larger pieces of level data in a simple manner.
edit: tepples beat me to it, for some reason the forum didn't warn me as it usually does
It's basically a sprite made out of multiple smaller hardware sprites. So one way to define a metasprite is with a bunch of data that your code knows how to interpret when writing to the sprite buffer.
Similar terminology is used with metasprites = a collection of smaller sprites, and a common way to compress larger pieces of level data in a simple manner.
edit: tepples beat me to it, for some reason the forum didn't warn me as it usually does
Re: SNES Newbie
Ah, okay, makes a ton of sense.
Thanks, guys!
Thanks, guys!
Re: SNES Newbie
Hmm, I've been trying to look more into the SPC-700 and implement the SNES GSS audio driver for my own game engine, but seem to have an issue.
The driver data is transferred into SPC RAM at $0200 and is executed, but once I set a GGS command, SPC is either always busy (which results in a endless check loop) or nothing happens.
Sorry if this is an idiotic post; I'm very ignorant to how the SPC-700 exactly works and have been understanding it by basically observing others' code.
The driver data is transferred into SPC RAM at $0200 and is executed, but once I set a GGS command, SPC is either always busy (which results in a endless check loop) or nothing happens.
Sorry if this is an idiotic post; I'm very ignorant to how the SPC-700 exactly works and have been understanding it by basically observing others' code.
Re: SNES Newbie
I'm not sure but I have a random suggestion. After you transfer the data to the SPC are you immediately issuing a command or do you let some time pass before then? Maybe you are too quickly trying to issue a command that the SPC program isn't ready and doesn't see your command and never gives the response the 65816 wants to see.
The other suggestion would be to try running your code in an emulator that lets you see both SPC and SCPU status in debug windows. Then you could really see why the deadlock happens.
The other suggestion would be to try running your code in an emulator that lets you see both SPC and SCPU status in debug windows. Then you could really see why the deadlock happens.
Re: SNES Newbie
You may have run into the same pitfall that I did initially - the first two bytes of the driver and music files exported from the SNESGSS tracker describe the byte size of those files, and therefore should not be transferred to the SPC.
SNES NTSC 2/1/3 1CHIP | serial number UN318588627
Re: SNES Newbie
Wow, you're a life saver. That did the trick; thanks a ton!HihiDanni wrote:You may have run into the same pitfall that I did initially - the first two bytes of the driver and music files exported from the SNESGSS tracker describe the byte size of those files, and therefore should not be transferred to the SPC.
I would have never figured that out on my own.
Re: SNES Newbie
That's super cool congratulations on your progress!
Now, that you have a huge animated sprite, some HMDA gradient, and sound working, you're all set to make a game! Do you have any plan for it yet?
Now, that you have a huge animated sprite, some HMDA gradient, and sound working, you're all set to make a game! Do you have any plan for it yet?
Download ROMs of my games: https://drludos.itch.io/
Support my work and get access to beta and prototypes: https://www.patreon.com/drludos
Support my work and get access to beta and prototypes: https://www.patreon.com/drludos
Re: SNES Newbie
Something akin to Super Smash Brothers, though not entirely sure yet!drludos wrote:That's super cool congratulations on your progress!
Now, that you have a huge animated sprite, some HMDA gradient, and sound working, you're all set to make a game! Do you have any plan for it yet?
There are still quite a few things I need to do before I'm ready to work on the game.