Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /storage/content/49/145849/famitracker.com/public_html/forum/classes/dbHandler.php on line 29
I was listening to this soundtrack that I was making to see if I made any mistakes. And this happened: [url=https://www.youtube.com/watch?v=wyJpHTM3pJ4]https://www.youtube.com/watch?v=wyJpHTM3pJ4
The reason for this was that the song I was listening to had 7 frames, and I wanted the last one to repeat over and over again. However, I had accidentally put down "B08" instead of "B07" which made the song skip to a frame that didn't exist. So instead of just looping to the nearest frame like FT did, the NSF file totally broke down :P
On the bright side, I managed to rip these samples. Most of them are just garbled junk of screeches you would find in an H.R.Giger film, but one could be used for a sawtooth bass (like in The Immortal.)
_______________________
I am everywhere. I am nowhere. I am everyone. I am no one. I am Darkman.
...No wait, that's not how it goes.
It's always worth trying to target game code with the DPCM unit, you might find some usable sounds actually! (I found this scratch noise in Megaman 3, and thought it could be used here and there)
Xiphos, you should run that NSF through rainwarrior's NSF importer! It would be really cool to see how some of those sounds got "made," especially at around 1:02 and 1:06, and to see what's going on at 1:52.
These samples are part of the driver program data and I think some pattern data. You can try to make samples of any data and get similar results, just try to load any file as a DPCM sample.
@modus I don't have the NSF file anymore, but I can try to re-create it. I'll try that immediately. However, I'm having trouble with getting the same effect. Ugh
@tadpole thanks!
@jbilling What do you mean by pan? Just wondering.
@jsr That's cool! I should try that sometime.
I found out what was going on with those samples. They were being played at random low pitches. And the thing that was going on at 1:52 was a looping sample. What it really is is just a small little "du-" as I like to call it, being looped continuously.
Panning, fading the sound between the left and right channels in stereo. Like at the beginning where it alternates between left and right. The NES only has mono output...
That's the NSF player working. I actually created that effect to create an echo sound (I also did it with one channel, which is only done when only one out of 2 square channels are available.) It creates a very different sound when played through NSF.
The behavior that you're experiencing is the DPCM wrap-around glitch that happens when the DMC register reads past $FFFF on a 32K ROM bank; and then wraps back around to the start of ROM space: $8000.
Normally the space for DPCM is $C000-$FFFF, you can either intentionally or unintentionally start to play code or data in other previously unreachable areas this way.
I'm not certain how the FamiTracker bankswitching code or DPCM sample loading code usually works but theoretically you could use a 16K "silent" DPCM sample and perhaps add a byte at the end of it and use Yxx commands to see if you could flip the read back over to $8000 to achieve the glitch.
If anybody wants to try, I'd be curious to the results. Also you could try a previous version of FamiTracker without DPCM bankswitching enabled.
It could wrap-around, but that only happens at the end of the last sample. It's more likely that a page from the driver area was swapped in into the sample area instead, since the page number is stored along with the sample address. Both might be "random" when undefined pattern data is being read.
Interesting. I do have a few questions, though: What exactly causes DMC registers to read what they do? Such as like (I'm pulling this number right out of my butt, BTW) $F164? And is this number any different for 7-bit DPCM? This sort of thing is actually pretty interesting.
Well, the 2a03 $4011 7-bit PCM DAC only does write streaming, unlike the MMC5 8-bit PCM DAC that also does read-streaming. So you supplying an "address" to $4011 like $F164 would likely just stream those two bytes; sounding like hardly anything.
Also there is no such thing as 7-bit DPCM. DPCM is 1-bit encoded data that either tells the DAC to move up or down, but can never flatline. You are thinking of 7-bit PCM. Take the Zxx command for instance. This does direct writes of bytes to $4011. The max values to write are $00 through $7F; bits 0 through 6 of the register. This plays your 7-bit PCM samples. FamiTracker can only do $4011 PCM with very fast sequencer tick speeds. "Pitches" could be achieved by x of the Fxy command.
$4012 loads a DPCM sample address, like $F164. $4013 says how long it is. And $4010 tells what speed (frequency/pitch) it should play it at.
I swear someone told me that bit 7 of $4011 is for the delta decoding for DPCM and cannot be written to or read. Not finding corroborating evidence of it at the moment.