|
ForumsSega Master System / Mark III / Game GearSG-1000 / SC-3000 / SF-7000 / OMV |
Home - Forums - Games - Scans - Maps - Cheats - Credits Music - Videos - Development - Hacks - Translations - Homebrew |
![]() |
Author | Message |
---|---|
|
FM / PSG mix - testing the audio control port
![]() |
There still seems to be some confusion about how to mix PSG and FM on systems that have both available. The problem is that there's very few software that even tries to do this, basically just the japanese BIOS and ValleyBell's Sonic FM hack. I read through the thread regarding the latter and couldn't really make heads or tails of what was being reported, as it seems at least partially contradict the information on the development page.
I think a few more tests are in order to find out what's really going on. Here's a little test ROM that I made. It plays a jolly little tune on both the SN76489 and the YM2413. With the d-pad of controller 1 you can choose which value gets sent to the audio control port. It also shows which value gets read back from there. Please try out the attached ROM and report your findings. I'm especially interested in the results on the japanese SMS, the Mark III plus FM unit combo, and the PowerbaseFM. Which sound output can you hear? If you deactivate one, does the sound cut off immediately or does the last note played linger? I'll start with the systems I have access to. First value is the one that's written to the acp, the second one is the one that's read from there. The third one is read again, but with I/O interference switched back on. European SMS with VileTim FM board: ---------------------------------------------------- 00 00 00 both chips audible 01 01 01 only FM, PSG is muted immediately 02 00 00 both chips audible 03 01 01 both chips audible European SMS, FM board switched off: ---------------------------------------------------- 00 02 06 only PSG 01 02 05 only PSG 02 02 03 only PSG 03 02 07 only PSG Analogue Mega SG: ---------------------------------------------------- 00 00 00 both chips audible 01 01 01 both chips audible 02 00 00 both chips audible 03 01 01 both chips audible |
|
![]() ![]() |
|
|
![]() |
I've been testing with an european SMS wiith Viletim's Board, and with a PowerBase FM:
European SMS with VileTim FM board: ---------------------------------------------------- 00 00 00 both chips audible 01 01 01 both chips audible !! 02 00 00 both chips audible 03 01 01 both chips audible European SMS, FM board switched off: ---------------------------------------------------- 00 02 06 only PSG 01 02 05 only PSG 02 02 03 only PSG 03 02 07 only PSG PowerBase FM ---------------------------------------------------- 00 00 00 both chips audible 01 01 01 both chips audible 02 00 00 both chips audible 03 01 01 both chips audible |
|
![]() ![]() |
|
|
![]() |
I'll see if I can get you results for both the Mark III+FM Unit and JP SMS. My Master Everdrive's in another location right now so it might take a little bit. I'll edit this post again with my findings.
EDIT: Here's the results: JP SMS 00 00 00 - PSG only 01 01 01 - FM only 02 02 02 - No audio 03 03 03 - Both audible Mark III with FM Unit 00 00 00 - PSG only 01 01 01 - FM only 02 00 00 - PSG only 03 03 01 - FM only Also, on all the results the audio cuts out immediately and doesn't linger. |
|
![]() ![]() ![]() |
|
|
![]() |
Thanks for testing. Those results are certainly quite interesting. I have edited the development page with the new information.
@kusfo: It's very interesting that you get different results on input $01 than me, despite also using a VileTim FM board. I think it's possible that we have different revisions of the hardware in use. Or maybe it's dependent on the host system? Mine's an early model SMS 1 with snail maze BIOS. @ApolloBoy: Your results pretty much confirm our assumptions on the functionality of the audio control port. It's good to finally have proof. However, it also confirms that it's impossible to have PSG and FM combined on a Mark III. Bummer. By the way: Would you mind testing on your Mark III with the FM unit detached to confirm it acts the same as an SMS without FM hardware? |
|
![]() ![]() |
|
|
![]() |
Yes, it was quite extrange to get these different results. I was thinking maybe I was not noticing the PSG going silent, but it was not the case at all (but I can do a video just in case)
My Master System is a 1 model with Safari hunt and Hang On included. The Viletim board is a V2 version, I think. |
|
![]() ![]() |
|
|
![]() |
There's one strange effect that I'm experiencing when running the test ROM on the Mega SG: The FM seems to randomly drop notes.
I thought it might have to do with sending data to the port too fast, and indeed I found a few places in the code where that happened, but fixing these changed nothing. Anyone experienced anything like this on any setup? On my SMS with VileTim board it plays just fine. It did that before, too, though, even with accessing the FM port too fast. Anyway, here's a new version of the test ROM with the FM access fixed. I also managed to synchronize the two chips a little better, so it sounds slightly better than the previous version. If you do any further testing, please use the new version. EDIT: Apparently, this is a known issue and YM2413 support on the Mega SG is simply broken. Hopefully, a future firmware revision will take care of it. |
|
![]() ![]() |
|
|
![]() |
I just checked, and my FM board is a V2.2. If you have a 2.1 or 2.0, that might explain the difference. |
|
![]() ![]() |
|
|
![]() |
|
|
![]() ![]() ![]() |
|
|
![]() |
I must admit that the last line puzzles me. The way the test is set up, it shouldn’t actually be possible that the third number is lower than the second one. I think the line should read either 03 01 01 or 03 03 03. Could you double-check, maybe? |
|
![]() ![]() |
|
|
![]() |
I bought it in 2013, so it should be 2.0 |
|
![]() ![]() |
|
|
![]() |
I pulled out my Mark III again and here's the second take: 00 00 00 - PSG only 01 01 01 - FM only 02 00 00 - PSG only 03 01 01 - FM only |
|
![]() ![]() ![]() |
|
|
![]() |
Brilliant. Thanks for confirming. | |
![]() ![]() |
|
|
![]() |
Oh and I also saw that you wanted me to do the test without the FM Unit attached, so here are the results from that:
00 06 06 - PSG 01 05 05 - PSG 02 03 03 - PSG 03 07 07 - PSG |
|
![]() ![]() ![]() |
|
|
![]() |
Very interesting, thanks. | |
![]() ![]() |
![]() |