N-SPC Engine/Imagitec Design
Go back to N-SPC Engine
Imagitec Design is a company that used the N-SPC engine for most of its games. Most of these games don't actually support music and sound effects played together: only the earliest version does.
Game Name | Version | VCMD Table Location ($E0 and up) | ROM Offset |
---|---|---|---|
Top Gear/Top Racer | 1.0 | 0x0B89, relative to 0x0AC9 | 0x0DE000 (all versions) |
American Gladiators | 2.0 | 0x0B87, relative to 0x0AC7 | 0x1E8000 |
The Humans | 2.0 | 0x0B87, relative to 0x0AC7 | 0x048000/0x058000/0x12C0FE (RNC compressed) |
Dragon's Magic (Konami logo) | 2.0 (Motivetime branch) | 0x0B80, relative to 0x0AC0 | 0x08C2BB |
Wheel of Fortune (Title Screen) Wheel of Fortune - Deluxe Edition (Title Screen) |
3.0a | 0x0BAF, relative to 0x0AEF | 0x0FB59C (all versions) |
Wheel of Fortune (In-Game) Wheel of Fortune - Deluxe Edition (In-Game) |
3.0b | 0x0775, relative to 0x06B5 | 0x0C8000/0x0DD7D3 (all versions) |
The raw build sorting notes can be found here.
The only modification made to the VCMD formats are to remove the fast forward and channel mute VCMDs and fast forward phrase commands, and to allow the end phrase command (and/or a second note duration/quantization/velocity combo) to execute rather than playing an invalid note.
Communication with the SNES
All values are usually echoed back straight to the SNES on the register they were written to.
Commands (V1.0)
This is the only version to support playing sound effects in tandem with the music.
CPUIO0 ($2140/$F4)
This register is purely responsible for controlling the music. $00 stops the music, while $01-$FF play music.
CPUIO1 ($2141/$F5)
This register is constantly polled every tempo tick.
Command ID | Description | Register Values & Arguments |
---|---|---|
$00 | Pass-Through | ?? $00 ?? ?? |
$01 | Stop Sound (Channels 5-8) | ?? $01 ?? ?? |
$02 | Car Engine Init (Channel 5) | ?? $02 ?? ?? |
$03 | Car Engine Speed (Channel 5) | ?? $03 xx yy |
$04 | Pass-Through | ?? $04 ?? ?? |
$05 | Play SFX (Channel 6) | ?? $05 ?? ?? |
$06 | Stop Sound (Channels 6-8) | ?? $06 ?? ?? |
$07 | Play SFX (Channel 5) | ?? $07 ?? ?? |
$08 | Play SFX (Channel 6) | ?? $08 ?? ?? |
$09 | Play SFX (Channel 6) | ?? $09 ?? ?? |
$0A | Play SFX (Channel 6) | ?? $0A ?? ?? |
$0B | Play SFX (Channel 6) | ?? $0B ?? ?? |
$0C | Pass-Through | ?? $0C ?? ?? |
$0D | Car Engine Init (Channel 7) | ?? $0D ?? ?? |
$0E | Car Engine Speed (Channel 7) | ?? $0E xx yy |
$0F | Pass-Through | ?? $0F ?? ?? |
$10 | Play SFX (Channel 8) | ?? $10 ?? ?? |
$11 | Stop Sound (Channels 6) | ?? $11 ?? ?? |
$12 | Play SFX (Channel 7) | ?? $12 ?? ?? |
$13 | Play SFX (Channel 8) | ?? $13 ?? ?? |
$14 | Play SFX (Channel 8) | ?? $14 ?? ?? |
$15 | Play SFX (Channel 8) | ?? $15 ?? ?? |
$16 | Play SFX (Channel 8) | ?? $16 ?? ?? |
$17 | Play SFX (Channel 8) | ?? $17 ?? ?? |
$18 | Stop Music + Go to IPL Boot ROM | ?? $18 ?? ?? |
$19 | Pause Sound | ?? $19 ?? ?? |
$1A | Play SFX (Channel 6) | ?? $1A ?? ?? |
$1B | Play SFX (Channel 8) | ?? $1B ?? ?? |
$1C | Play SFX (Channel 6) | ?? $1C ?? ?? |
$1D | Play SFX (Channel 8) | ?? $1D ?? ?? |
$1E-$FF | Pass-Through | ?? ?? ?? ?? |
Pass-Through
Effectively a NOP, doing nothing.
Stop Sound
Disables the channel(s) indicated by ID as long as this command is the last ID sent...
- $01 - Channels 5-8
- $06 - Channels 6-8
- $11 - Channel 6
Play SFX
Plays a piece of SFX. It seems like an array could be used here, but it isn't: instead, it's just an 8-byte entry to a series of DSP register writes to the Vx DSP registers before keying it on, with the channel and sound used varying by ID.
Car Engine Init (Command $02, $0D)
?? ii ?? ??
- ii, the command ID used for the SFX, defines the channel used.
- Channel 5: $02
- Channel 7: $0D
Car Engine Speed (Command $03, $0E)
?? ii xx yy
- ii, the command ID used for the SFX, defines the channel used.
- Channel 5 (V4PITCH): $03
- Channel 7 (V6PITCH): $0E
- xx is a direct write to the VxPITCHL DSP register.
- yy is a direct write to the VxPITCHH DSP register.
Pause Sound (Command $19)
Mutes everything while this command is the last ID sent.
Stop Music + Go to IPL Boot ROM (Command $18)
Uses the FLG DSP register to disable echo writes, mute the amplifier and key off all voices, then jumps to the IPL Boot ROM.
Commands (V2.0)
This code is nearly identical to Controller Test, except for the VCMD differences mentioned above, this command set, and a couple of other minor differences.
Command ID | Description | Register Values & Arguments |
---|---|---|
$00 | Stop Sound | $00 ?? ?? ?? |
$01-?? | Play Music | xx ?? ?? ?? |
$FF | Go to IPL Boot ROM | $FF ?? ?? ?? |
Commands (V2.0 Motivetime Branch)
The only difference is that Go to IPL Boot ROM is instead executed through VCMD $E2 (overwriting it in the process), along with stopping the sound.
Command ID | Description | Register Values & Arguments |
---|---|---|
$00 | Stop Sound | $00 ?? ?? ?? |
$01-?? | Play Music | xx ?? ?? ?? |
Commands (V3.0a)
Command ID | Description | Register Values & Arguments |
---|---|---|
$00 | Stop Sound | $00 ?? ?? ?? |
$01-$7F | Play Music | xx ?? ?? ?? |
$41 | Mute | $41 xx ?? ?? |
$41 | Mute + Go To IPL Boot ROM | $41 $58 ?? ?? |
$80-$FF | NOP | ?? ?? ?? ?? |
NOP
Does absolutely nothing. Doesn't even acknowledge.
Mute
Mutes the sound by zeroing out the main volume and zeroing out the DSP registers.
$41 xx ?? ??
- xx, when set to $58, jumps to the IPL Boot ROM. Interestingly, that means that this command spells out AX in ASCII.
Commands (V3.0b)
The phrase format has been massively modified to only have one channel, meaning the pointer goes directly to pattern data. You can still loop the now one-channel phrase pointer, though. The sub-routine command becomes a straight-up jump command due to the phrase termination command (ID $00) having been stripped of handling sub-routine code.
Commands (V3.0b)
Command ID | Description | Register Values & Arguments |
---|---|---|
$00 | Stop Sound | $00 ?? ?? ?? |
$01-$0F | Play Sound | $0x ?? ?? ?? |
$10-$40 | NOP | ?? ?? ?? ?? |
$41 | Mute | $41 xx ?? ?? |
$41 | Mute + Go To IPL Boot ROM | $41 $58 ?? ?? |
$42-$FF | NOP | ?? ?? ?? ?? |
NOP
Does absolutely nothing. Doesn't even acknowledge.
Play Sound
$0x ?? ?? ??
- x is the sound ID. All sounds play on channel 1. These are uninterruptible unless stopped with the $00 command first.
Mute
Mutes the sound by zeroing out the main volume and zeroing out the DSP registers.
$41 xx ?? ??
- xx, when set to $58, jumps to the IPL Boot ROM. Interestingly, that means that this command spells out AX in ASCII.