Test VRC7 audio (incl. custom instrument)

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
Test VRC7 audio (incl. custom instrument)
by on (#96827)
I have written a program for the VRC7 audio: http://zzo38computer.org/nes_program/vrc7test.zip It includes source and binary for running in NES/Famicom emulator, or on a real VRC7 hardware if you have it. This program is public domain.

[I posted message in another section of the forum but you can remove that one; it doesn't work so well as this updated one]
Re: Test VRC7 audio (incl. custom instrument)
by on (#196659)
Sorry for the five year bump, but a friend was asking about whether someone could make a VRC7 instrument tester, like the one CopyNES has but as a native ROM, so they could use it to try and refine the existing patch set.

I tried this ROM but I can't seem to get it to work. Every emulator I try seems to do something different, but none of them seem to have a working "cursor". Nintendulator has a black screen. FCEUX is unresponsive. Nestopia makes a high pitched whine and is otherwise unresponsive. puNES has the picture scrolled wrong unless you are holding a button...

What emulator did this originally work on?


This was the original version referred to, by the way: http://forums.nesdev.com/viewtopic.php?f=22&t=9093#p96785
Re: Test VRC7 audio (incl. custom instrument)
by on (#196663)
I've found it to work with VirtuaNES 0.97. And also Nester 0.51b (with not-so-great sound quality).
Re: Test VRC7 audio (incl. custom instrument)
by on (#196796)
Unfortunately I did not know so well how to write it at the time, so I did not to do a good job, sorry. It fails to clear the RAM and fails to do other important stuff too
Re: Test VRC7 audio (incl. custom instrument)
by on (#229302)
Thanks for this. Helped me debug my issues with porting an FPGA implementation of the YM2413 into MiSTer.
I did have to fix one issue with the code:
Code:
rt:
   rti

needs to be after this line:
Code:
   dec <pushed

This code should not fall through to the npu: section.

I modified it slightly differently, but that should be the same effect as what I did (modified by hand in a hex editor the nes file as I don't have a compiler set up on my computer).

There are issues with initialization of values (push up or down on each number to update them at least once), and I think a palette isn't being set? The initialization could be fixed by setting the 25 bytes at valmem to 0 at start.
But in spite of this, it works and it helped.

Edit: Also, does anyone know the default/reset value of the audio silence bit (0xe000-bit 6)? The test rom doesn't set this.

Thanks again.