It is currently Thu Dec 14, 2017 8:19 am

All times are UTC - 7 hours





Post new topic Reply to topic  [ 35 posts ]  Go to page Previous  1, 2, 3
Author Message
PostPosted: Thu Nov 08, 2012 12:08 pm 
Offline
User avatar

Joined: Fri Nov 19, 2004 7:35 pm
Posts: 3968
If you're looking for a good MMC3 test program that breaks a lot of emulators, try my Chu Chu Rocket homebrew game.

_________________
Here come the fortune cookies! Here come the fortune cookies! They're wearing paper hats!


Top
 Profile  
 
PostPosted: Thu Jan 24, 2013 10:27 am 
Offline
User avatar

Joined: Sat Jan 22, 2005 8:51 am
Posts: 427
Location: Chicago, IL
koitsu wrote:
When firing Megaman's gun, there is what sounds like a bass-y "fart" noise at the end of the effect.

miker00lz wrote:
Yeah, you're right I can hear the fart noise.

Did you ever find the cause of this? I'm currently writing my APU emulation code (moving off of Blargg's nes_snd_emu library) and have run into the same issue. Here's what's being output from the square2 channel when Mega Man jumps off of the title screen. The fart noise is the low frequency wave between the higher frequency chunks.

Image

Here's a log of writes to the channel. The first column is the sample number (multiply by 37 to get CPU cycle). The writes are time (s.ms): address - value, and the interspersed lines represent changes in square channel output (envelope volume, output yes/no, sweep unit output, timer period, and length counter value).
Code:
00146109: 0009 0001 0001 0114 0254
00146115: 0009 0000 0001 0114 0254
00146159: 0009 0001 0001 0114 0254
00146165: 0009 0000 0001 0114 0254
00146208: 0009 0001 0001 0114 0254
00146215: 0009 0000 0001 0114 0254
00146258: 0009 0001 0001 0114 0254
00146264: 0009 0000 0001 0114 0254
00146308: 0009 0001 0001 0114 0254
00146314: 0009 0000 0001 0114 0254
00146358: 0009 0001 0001 0114 0254
00146364: 0009 0000 0001 0114 0254
00146407: 0009 0001 0001 0114 0254
00146414: 0009 0000 0001 0114 0254
00146457: 0009 0001 0001 0114 0254
00146463: 0009 0000 0001 0114 0254
00146507: 0009 0001 0001 0114 0254
00146513: 0009 0000 0001 0114 0254
00146540 57.877: 4004 - 39
00146544 57.877: 4006 - 33
00146554 57.877: 4015 - 07
00147344 57.888: 4004 - 39
00147348 57.888: 4006 - F4
00147349 57.888: 4007 - FF
00147358 57.888: 4015 - 07
00148011: 0009 0001 0001 2036 0030
00148122: 0009 0000 0001 2036 0030
00148149 57.898: 4004 - 39
00148153 57.898: 4006 - B5
00148163 57.898: 4015 - 07
00148872: 0009 0001 0001 1973 0030
00148954 57.908: 4004 - 39
00148958 57.908: 4006 - 76
00148968 57.908: 4015 - 07
00148979: 0009 0000 0001 1910 0030
00149702: 0009 0001 0001 1910 0030
00149759 57.919: 4004 - 39
00149763 57.919: 4006 - 37
00149773 57.919: 4015 - 07
00149805: 0009 0000 0001 1847 0030
00150504: 0009 0001 0001 1847 0030

As far as I can tell, I'm correctly outputting sound based on the values being written to $40xx. And when comparing my code to other emulators, everything looks ok. I'm stumped.

_________________
get nemulator
http://nemulator.com


Top
 Profile  
 
PostPosted: Thu Jan 24, 2013 11:54 am 
Offline
User avatar

Joined: Mon Sep 27, 2004 8:33 am
Posts: 3715
Location: Central Texas, USA
James wrote:
moving off of Blargg's nes_snd_emu library

At first I was going to ask what motivated this, then I saw it was off my APU code, not the resampling library. Your own APU code; more power to you! It's fun to implement.

As for the problem sound, I bet you aren't implementing the sweep's silencing of a channel when its frequency gets too low. Remember that this occurs even when sweep is disabled. I haven't looked over your log, just taking a guess.


Top
 Profile  
 
PostPosted: Thu Jan 24, 2013 12:10 pm 
Offline
User avatar

Joined: Sat Jan 22, 2005 8:51 am
Posts: 427
Location: Chicago, IL
blargg wrote:
James wrote:
moving off of Blargg's nes_snd_emu library

At first I was going to ask what motivated this, then I saw it was off my APU code, not the resampling library. Your own APU code; more power to you! It's fun to implement.

It was fun -- then I ran into this issue :lol:. Thanks, by the way, for the library and all the documentation!

Quote:
As for the problem sound, I bet you aren't implementing the sweep's silencing of a channel when its frequency gets too low. Remember that this occurs even when sweep is disabled. I haven't looked over your log, just taking a guess.

Unfortunately, that's not it.

_________________
get nemulator
http://nemulator.com


Top
 Profile  
 
PostPosted: Thu Jan 24, 2013 12:25 pm 
Offline
User avatar

Joined: Sat Jan 22, 2005 8:51 am
Posts: 427
Location: Chicago, IL
James wrote:
blargg wrote:
As for the problem sound, I bet you aren't implementing the sweep's silencing of a channel when its frequency gets too low. Remember that this occurs even when sweep is disabled. I haven't looked over your log, just taking a guess.

Unfortunately, that's not it.

Actually, that's exactly what it is :oops:. I completely misunderstood what was going on there...

Thanks!!!

_________________
get nemulator
http://nemulator.com


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 35 posts ]  Go to page Previous  1, 2, 3

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group