ASM Tutorial Part 1
So... you want to make a block that freezes Mario only when he's small?
So... you want to make a block that freezes Mario only when he's small?
Are you familiar with all the previous lessons yet? If so, that's great.. with all of that knowledge, you can do a lot of cool stuff - but you can always get better at ASM and make awesome stuff by learning more. So here's Part 2 of the tutorial, which for now only explains a bit of intermediate stuff. Don't worry, everything will be explained easily.
So... you know ...
BS-X MMIO
The SNES has 8 background modes, two of which have major variations. The modes are selected by bits 0-2 of register $2105
.
Mode # Colors for BG
1 2 3 4
======---=---=---=---=
0 4 4 4 4
1 16 16 4 -
2 16 16 - -
3 256 16 - -
4 256 4 - -
5 16 4 - -
6 16 -
SNES Controllers
Offset | Description | Info |
---|---|---|
043DAA |
Audio / Sample Indexes | |
100200 - 102FFF? |
Enemy Data | |
11020D - 110734 |
Weapon Data | |
110812 ... |
Below is a decompressor and recompressor for GD Leen. This has been updated to compile with GCC, below that is the original unmodified file.
//------------------------------------------------//
// Decompressor and Recompressor: GDLeen ver 1.0 //
// //
// Coded By: John C. (Bongo`) ...
Version 1.0 - Copyright 2003: The Dumper
The Game Doctor SF3/SF6/SF7 backup units for the SNES use a 512 byte header.
The format is as follows (all numbers are hexadecimal):
0000-000F
47 41 4D 45 20 44 4F 43 54 4F 52 20 53 46 20 33 "GAME DOCTOR SF 3"
This is the ID string for a Game Doctor SF header.
0010
SRA ...
The most important thing to know about 65816 optimizations is to not try to emulate other CPU architectures. A lot of games (games with a lot of slowdown) have this programming style where the programmer pretends that a couple memory locations are 68000 registers or high-level local variables, and the accumulator is only there as an operand buffer. Please avoid this style of programming. It is
DMA can move data from ROM/WRAM->VRAM/CGRAM/OAM or ROM->WRAM. You can also use HDMA to modify per each line, this shows you how.
Subtraction and Mask Windows on the SNES
This is a tutorial on 65816 ASM used in the SNES, made easy for dumb people to understand (sorta). In case you are wondering, I don't program in this language, so it is possible that I will write something incorrectly in this tutorial. If so, you can e-mail me at tennj@yahoo.com, to complain about how I suck at tutorials. Learning ASM language isn't easy. If ...
Aceman2000's Tic-Tac-Toe tutorial
Megaman X3 / Rockman X3
Nintendo Music Format (N-SPC) player is a common SPC player included in many SNES games.
Old BBS Messages related to SNES or Programming
bazz's controller input tutorial
SNES Memory Mapped I/O Registers
Rendering the Screen: Mosaic, Color Math
S-DD1
The SA-1 is a coprocessor capable of running at four times the base speed of the SNES main CPU when access does not conflict with that of SNES CPU, DMA or HDMA processing. It provides additional shared RAM, visible to both the SNES CPU and the SA-1, and optionally backed up by battery referred to as BW-RAM with a maximum install RAM size of 256 KB (2 Mbit).
SA-1 Co-Processor Registers
SFCサウンドマニュアル (SFC Sound Manual)
SFROM File Format
Sprites are important to every game.
SPC700 Audio Processor Reference
SPC7110 Decompression Chip
The satellaview AV selector was conceived in order to prepare the decoded satellite signal for the satellaview, prevent the super famicom from monopolizing the TV's AV input, and allow for the use of a second BS decoder along with the one provided by ST. Giga. As is evident in the following diagram, the selector's internal circuit can be divided in three discrete units, ...
Change Register names
Soundlink, also known as "Live Voice" and various other aliases, is a Satellaview function in which Streaming Satellite Radio from St.GIGA is played at the same time as software data is broadcast, downloaded and played. This is intended to give the illusion of a game being played with high-quality audio. This was a selling feature of the Satellaview and was used in a lot of it's software.
Soun ...
This is a document intended to describe the various hardware ports on the SNES.
This is a guide to the Secret of Evermore SRAM, the section of memory in the Secret of Evermore cartridge used to save your progress.
Secret of Evermore, like most SNES games, used an SRAM of 0x2000
(8 KB) bytes to sto
Seiken Densetsu 2 / Secret of Mana
The SNES has 128 independent sprites. The sprite definitions are stored in Object Attribute Memory, or OAM.
Star Ocean data offsets, values, and technical information.
The following information is for the US version of the game.
Offset | Description |
---|---|
1F4A5 - 1F4F8 | Track Data pointers (3 bytes per track, 28 tracks) |
28000 | Menu "Track" Data |
28074 | 00- ... |
Community eratta for the offical documentation from Nintendo
Once you've programmed a game or other bit of data for SNES, you'll probably want to try to, well, test it.
Although for most software these choices are, mostly, about preference. Most games which require Expansion Chips other than the DSP-1 may require less than favorable methods of testing (either emulation or reproduction cartridge).
...
This is a document intended to describe various aspects of SNES timing. It will probably not be useful unless you already know a good bit about the SNES.
Widespread Programming Myths, These are myths that frequently show up that mislead people into writing bad code based on false perception of what the system actually does.
The windows can be used to mask off a portion of any BG on the scanline.
Winkysoft Music Format of Super Robot Wars 4
Part 1 of bazz's VRAM tutorial
Part 2 of bazz's tutorial