Page 3 of 3
Posted: Sat Feb 01, 2014 4:57 pm
by sigflup
YESSSSSSSSSSSSSS!!!!!!!!!!!!!!!!! Getting rid of that 67 66 00 00 00 00 totally worked
Posted: Sat Feb 01, 2014 5:42 pm
by kubilus1
Sigflup, I committed an update to the VGM driver code that should solve the empty PCM data block problem. You should be able to pull this and sync it with your changes.
Yeah, the problem is normally when specifying the length of a PCM data block, the you add the length to vgm address *before* the data length portion. Essentially this requires reading in this length and then subtracting 4 bytes.
In the case of a PCM data block of length 0, subtracting 4 bytes is incorrect, since that is essentially trying to get the system to process opcode 0, which doesn't exist.
Posted: Sat Feb 01, 2014 6:01 pm
by kubilus1
Bastien, the Dr_optimized file is using 16khz samples, that's why it is playing too slow. Resample these to 8khz, if possible.
Posted: Sat Feb 01, 2014 6:35 pm
by kubilus1
Forget what I said abut subtracting 4 bytes, I misunderstood something. I've updated the source to fix this.
Posted: Sat Feb 01, 2014 6:41 pm
by kubilus1
Updated vgm_drv:
https://dl.dropboxusercontent.com/u/101302896/vgm_drv.h
This should fix certain VGM files that have empty PCM blocks and probably some other problems as well.
Posted: Mon Feb 03, 2014 12:09 am
by Stef
Cool, i just updated SGDK and included your ast version of the VGM driver

Posted: Mon Feb 03, 2014 12:40 am
by kubilus1
Sounds great! I appreciate the feedback on the driver. Let me know if there are any more files that have problems playing.
Posted: Mon Feb 03, 2014 9:39 am
by Stef
For now the last version seems to work quite nicely ! I will report any problems if i meet some with =)
Posted: Thu Feb 06, 2014 7:07 am
by sigflup
The average 68k memory access for my musicdisk is about 8.8Kb/s. That equates to at most 1.6K cycles lost on the 68k's clock every NTSC frame. Which isn't that bad, I guess. About how many instructions would you as assume 1.6k cycles is?
personal stuff....
I'm noticing skipping on my program and I think it's because my main loop gets extended beyond a frame by the z80. I could be wrong on this.