Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up --- Bug Reports --- Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Soundcard frequency stability test - please add your results  (Read 10448 times)

0 Members and 1 Guest are viewing this topic.

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Soundcard frequency stability test - please add your results
« on: October 20, 2013, 04:32:54 am »
Hi,

I noticed something interesting that is affecting GroovyMAME (audio) emulation accuracy. Short introduction first on the issue and then for the test and test results. It's also a very simple test, so if you have a minute, please report back, and I'll collect them in this first post.

One part in the chain of accurate emulation is the soundcard frequency stability, i.e. does it always exactly return the requested playback rate? Because if not, it will lead to a more unstable soundbuffer, which will cause soundbuffer over-/underflows (missing audio) at lower audio latency settings. Or said differently, the more stable the soundcard, the lower you can set the MAME audio latency without it causing issues, the more accurate the emulation gets.

Because GM didn't seem to be able to get as low a -stable- sound latency as I would expect it to be able to for DirectSound (the windows api used by MAME), I've been digging around deeper. First in the code, which didn't help, then looking at the soundcards more closely. Now to my total surprise I found that on two of my high end PC's, the high end soundcards that I've got in there (one an Auzentech X-Fi Forte and the other a Creative SB X-Fi) don't deliver a stable rate at all! Switching over to the Realtek ALC898 onboard audio delivered rocksteady audio, and allowed me to lower the audio latency in GroovyMAME by quite some margin, very close to a setting of 1, -without- it leading to any buffer over-/underflows.

Doing the soundcard frequency tests for all three, showed how unstable both X-Fi cards were, and how very stable the Realtek ALC898 is! The tests are done with the tool FreqTest, which requests a sample played at 48Khz a number of times and calculates the actual frequency that is returned by the soundcard, providing a "min", "avg" and "max" value. Ideally these values are the same , as that means there's no invariabilty and as such the highest possible stability for MAME audio emulation.

Here are the results:
(EDIT: other user results added to the table. Order is from best to worse.)

CardMin (Hz)Avg (Hz)Max (Hz)OSInterfaceUser
Realtek ALC86148000,01848000,03048000,080Vista x64On-boardSMMM
Sound Blaster X-Fi XtremeGamer47998,99547999,0547999,099XP x64PCIKrick
Auzentech X-Fi Prelude 7.147998,72047998,81047998,897XP x86PCIGoglu2
Realtek ALC26947998,29847998,67647998,934W7 x64On-boardCalamity
Nvidia 550Ti (HDMI out)47998,44047998,45647998,472W7 x64PCI ExpressSMMM
SIGMATEL STAC 92XX C-Major HD Audio47998,20047998,24447998,275W7 x64On-boardCalamity
Realtek ALC892    47997,94647998,00247998,054W7 x64On-boardbulbousbeard
Realtek ALC887   47997,92747997,95147997,971W7 x64On-boardKrick
Realtek ALC85047997,93447997,94147997,959W7 x64On-boarddeathterrapin
Realtek ALC898    47997,25247997,26247997,292W7 x64On-boardDr.Venom
SIGMATEL STAC 92XX C-Major HD Audio48008,41548008,48548008,574XP x64On-boardCalamity
Realtek ALC66247973,22147976,50747993,630XP x64On-boardCalamity
C-Media USB CM10647997,93248002,74248045,940W7 x64USBdeathterrapin
VIA VT1828S47997,24548002,06048045,268W7 x64On-BoardSMMM
Auzentech X-Fi Forte   47997,23248002,05748045,257W7 x64PCI ExpressDr.Venom
C-Media USB unknown (0D8C 000E)47973,47147975,03747978,460XP x64USBdeathterrapin
C-Media USB CM10647973,47847974,89947978,343XP x64USBdeathterrapin
Realtek ALC889 47950,41747993,64547998,486W7 x64On-BoardSMMM
Creative SB X-Fi   47949,26148006,38048045,260W7 x64PCI ExpressDr.Venom
Asus Xonar DG47949,25248006,86348093,336W7 x64PCISMMM
Realtek ALC889a47873,47247946,74748026,595W7 x64On-boardJDFan

Now, as can be seen the RealTek ALC898 delivered by far the most stable results when compared to both my Auzentech and Creative X-Fi cards. The Realtek results in the possibility to now set a much lower audio latency setting in MAME then with the X-Fi cards, without it causing audio issues (buffer over-/underflows).

Now I was actually quite surprised that the expensive high-end soundcards deliver such poor stability results. But it's not the first time we may be surprised on PC hard-/software.

Given this I'm wondering what the results are for other soundcards / OS setups? Hopefully you'll submit your own results. The procedure is actually quite simple:

1. Make sure that you have set your audio device in windows to work at 16-bit 48Khz (configuration->audio panel -> right mouse button on default audio device -> select properties and then "advanced" and set it to 16-bit 48000Hz). *Note: this first step is important, as having the default audio device at any other rate then 48Khz, will cause FreqTest to deliver false results, because of resampling between the requested 48Khz and the default rate set in Windows.*
2. Start the attached "FreqTest.exe" (the archive includes both a 32 and 64 bit version) and wait for a few minutes. It will first test the screen frequency and then the audio test. The result will be like the picture below. The relevant part "sample rate" is highlighted in the red square:



3. Report back here with your soundcard, OS and the "sample rate" results.

If possible, I'll collect all the other results in the first post, such that we build a list on the best / most stable audio cards for use with MAME. Even if your card is the same as already reported by someone else in the test results, then please still report back with your own, as the stability may possibly also be OS / driver dependant. The more information the better.
« Last Edit: November 04, 2013, 07:23:49 am by Dr.Venom »

deathterrapin

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 24
  • Last login:February 19, 2021, 07:06:53 am
Re: Soundcard frequency stability test - please add your results
« Reply #1 on: October 20, 2013, 06:24:56 am »
Realtek ALC850 47997.934    47997.941    47997.959    W7
C-Media USB CM106    47997.932    48002.742    48045.94    W7
C-Media USB CM106    47973.478    47974.899    47978.343    XP x64
C-Media USB unknown (0D8C 000E)    47973.471    47975.037    47978.46    XP x64

The first two of those are on my main pc, the others two on my cab pc.
I would suspect that the different behavior of the CM106 between the two is more to do with the different motherboard rather than the OS.

I'll be interested to see if anything useful comes out of this. I've never quite been able to get the audio perfect with groovymame on my cab pc.

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #2 on: October 20, 2013, 08:52:25 am »
Hi deathterrapin,

Thanks for adding your results. It's interesting to see that the Realtek soundchip is (again) delivering the most stable results. I'll add them to the first post.

I'll be interested to see if anything useful comes out of this. I've never quite been able to get the audio perfect with groovymame on my cab pc.

I'm not sure if I understand your comment "if anything useful comes out of this". In the first post it's explained that the more stable a soundcard, the better a solution it is for the audio emulation stability of MAME. So in your case - all else being equal - your MAME setup should include the Realtek ALC850, as it's the only one that's delivering fully stable sound output.

deathterrapin

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 24
  • Last login:February 19, 2021, 07:06:53 am
Re: Soundcard frequency stability test - please add your results
« Reply #3 on: October 20, 2013, 09:34:40 am »
I was thinking that it might be possible to modify the mame sound code to compensate for the unstable sound rates, now I think about it some more though that's probably just too hacky.

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7076
  • Last login:Today at 11:26:35 am
  • Quote me with care
Re: Soundcard frequency stability test - please add your results
« Reply #4 on: October 20, 2013, 02:11:19 pm »
Here goes mine:

Realtek ALC269 47998.298 47998.676 47998.934 W7 x64

Realtek ALC662 47973.221 47976.507 47993.630 XP x64

The first one gives much better results, but it was necessary to set 16 bit /48 kHz, by default it was setup as 24 bit and it gave worse results. This audio bitrate config menu does not exist under Windows XP (!!??), so I don't know if the bad results of the second case are due to this.
« Last Edit: October 20, 2013, 05:42:03 pm by Calamity »
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead or pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

deathterrapin

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 24
  • Last login:February 19, 2021, 07:06:53 am
Re: Soundcard frequency stability test - please add your results
« Reply #5 on: October 20, 2013, 04:08:19 pm »
Oh, my windows 7 machine is 64 bit as well btw. (I kind of forget there still is a 32 bit version sometimes :D)

bulbousbeard

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 522
  • Last login:August 25, 2015, 11:58:25 pm
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #6 on: October 20, 2013, 04:58:51 pm »
Realtek ALC892 on an Asus P8Z68-V PRO motherboard in Windows 7 x64

« Last Edit: October 21, 2013, 01:20:10 am by bulbousbeard »

JDFan

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3433
  • Last login:February 08, 2021, 11:57:13 pm
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #7 on: October 20, 2013, 06:34:51 pm »
realtek alc889a

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #8 on: October 21, 2013, 05:34:40 am »
@ JDFan: What OS are you using?   If it's W7, did you apply step 1, as described in the first post?

@ Calamity: with regards to XP, I understand that in XP by default a single stream is played at the requested rate without sample rate conversion, as long as the sound device is capable of that sample rate. So your measured results for XP should be good.

There is some conversion setting though in the advanced panel that may impact things, which I think would be good to check.  So just to be sure, could you test all three different "sample rate conversion" settings ("good, better, best") in the advanced audio properties panel, as shown in the picture below. In case one of them delivers worse results (i.e. indicating unwanted, time consuming sample rate conversion going on), then I can add those to the instructions.



With regards to the 16-bit 24-bit conversion in W7, I added the "16-bit" explicitly to the 48Khz setting instruction in step 1.
« Last Edit: October 21, 2013, 05:47:32 am by Dr.Venom »

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7076
  • Last login:Today at 11:26:35 am
  • Quote me with care
Re: Soundcard frequency stability test - please add your results
« Reply #9 on: October 21, 2013, 07:15:07 am »
Hi Dr., I did test that dialog with both "Better" and "Best" options and they didn't seem to make a change, I might test "Good" today too just to double check... it's a bit annoying when the OS hides the actual params under lame words.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead or pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7076
  • Last login:Today at 11:26:35 am
  • Quote me with care
Re: Soundcard frequency stability test - please add your results
« Reply #10 on: October 21, 2013, 07:24:25 am »
BTW the FreqTest program doesn't work under Win32.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead or pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #11 on: October 21, 2013, 11:05:20 am »
Hi Dr., I did test that dialog with both "Better" and "Best" options and they didn't seem to make a change, I might test "Good" today too just to double check... it's a bit annoying when the OS hides the actual params under lame words.

LOL, Indeed :)

BTW the FreqTest program doesn't work under Win32.

Ah ok, I've added the 32-bit one also to the archive now.

Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7076
  • Last login:Today at 11:26:35 am
  • Quote me with care
Re: Soundcard frequency stability test - please add your results
« Reply #12 on: October 21, 2013, 11:18:50 am »
Ok, one more:

SIGMATEL STAC 92XX C-Major HD Audio  47998.200 47998.244 47998.275 W7 x64
SIGMATEL STAC 92XX C-Major HD Audio  48008.415 48008.485 48008.574 XP x64

Note this is the same physical card tested under two different OSes on my multi-boot system (an old Dell P4 with Intel chipset). Results are almost as good in either system, so this reinforces the idea that the performance is hardware dependent rather than OS.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead or pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

JDFan

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3433
  • Last login:February 08, 2021, 11:57:13 pm
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #13 on: October 21, 2013, 12:29:17 pm »
@ JDFan: What OS are you using?   If it's W7, did you apply step 1, as described in the first post?

OS is win7 64 bit on a Gigabyte MOBO with realtek audio HD manager --I believe this is what you meant correct ?

Just rechecked the settings and somewhere win7 had changed the default to 24 bit rather than 16 bit for the speakers (Had looked at the digital output device originally) Here is the result after resetting the default for the speakers to 16 bit --
« Last Edit: October 21, 2013, 12:51:13 pm by JDFan »

brad808

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 818
  • Last login:January 22, 2021, 05:22:41 pm
Re: Soundcard frequency stability test - please add your results
« Reply #14 on: October 21, 2013, 12:56:30 pm »
The sample rate conversion slider shouldn't make a difference because it shouldn't be converting the sample rate.

Sent from my Nexus 4


krick

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2008
  • Last login:December 23, 2020, 12:54:14 pm
  • Gotta have blue hair.
Re: Soundcard frequency stability test - please add your results
« Reply #15 on: October 24, 2013, 12:24:35 pm »
I think it might be useful to note whether the tested sound chip is on the motherboard vs a plug-in card.  It's possible that the PCI/PCIe bus is adding to the stability issue.

Another thought is that overclocking may affect the results.  In addition to manual overclocking by users, some motherboards do automatic overclocking in some situations for a performance boost.

I have a PCI Sound Blaster X-Fi XtremeGamer on Windows XP x-64 that I need to test for you when I get the chance.  I'm curious if I see the same results as you.

I also wonder about the chosen sample rates.  I know that some older hardware was designed for a certain target sample rate and had to re-sample internally to output other sample rates if requested, which could impact the results.   I would assume that most hardware designed for the general public would target 16-bit / 44.1kHz since that's what's used for compact discs.
Hantarex Polo 15KHz
Sapphire Radeon HD 7750 2GB (GCN)
GroovyMAME 0.197.017h_d3d9ex
CRT Emudriver & CRT Tools 2.0 beta 13 (Crimson 16.2.1 for GCN cards)
Windows 7 Home Premium 64-bit
Intel Core i7-4790K @ 4.8GHz
ASUS Z87M-PLUS Motherboard

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #16 on: October 25, 2013, 05:10:45 am »
Just rechecked the settings and somewhere win7 had changed the default to 24 bit rather than 16 bit for the speakers (Had looked at the digital output device originally) Here is the result after resetting the default for the speakers to 16 bit --

Hi JDFan. Thanks for rechecking the settings. I'll add the updated results to the table.

Note this is the same physical card tested under two different OSes on my multi-boot system (an old Dell P4 with Intel chipset). Results are almost as good in either system, so this reinforces the idea that the performance is hardware dependent rather than OS.

This would indeed suggest that the OS doesn't influence the stability, that's good to know.

I think it might be useful to note whether the tested sound chip is on the motherboard vs a plug-in card.  It's possible that the PCI/PCIe bus is adding to the stability issue.

Hi Krick. I'll add the motherboard vs plug-in card to the table.

With regards to the reasons for the instability, those are some relevant point you bring forward. Let's take them one by one:

1. Overclocking / automatic performance boost.
I have an I7 3770k overclocked at 4.6Ghz and the Realtek (on-board audio) delivers rocksteady results but the X-Fi does not in the same machine. This would suggest that overclocking isn't the main reason. In any case we would need some hypothesis and tests to prove otherwise.

2. (older) hardware was designed for a certain target sample rate (that could be different than 48Khz)

"Assuming" that chips work at 44.1Khz based on old CD technology isn't good enough ;).  I could say the opposite based on the assumption that people use their PCs to play DVD's (i.e. audio at 48Khz)... Sadly there's very little evidence what the native frequencies are of soundcards. Apparently the newer Creative cards work at 48Khz; just read some of the (many) forums with users complaining about their cards resampling audio to 48Khz . I'm also reading that there would be chips that are capable of having more than than one single native sample frequency.

From my personal tests I can tell that for the X-Fi cards it makes no difference whether I use them (and the MAME setting) at 44.1Khz or 48Khz, both settings are much more unstable (more buffer over-/underflows at the same audio latency setting) then when using the Realtek chip. 

Testing at 48Khz seems the right thing to do, as it happens to be the default MAME audio rate. So unless users deliberately change that, 48Khz is what's being used.

3. Motherboard vs a plug-in card.  It's possible that the PCI/PCIe bus is adding to the stability issue.

If I were to place my bets, this is where it would be. The results up until now would have suggested so, if it were not for JDFan's results: his Realtek onboard audio delivers about as unstable results as the X-Fi cards.

Quote
I have a PCI Sound Blaster X-Fi XtremeGamer on Windows XP x-64 that I need to test for you when I get the chance.  I'm curious if I see the same results as you.

Yes that will be interesting to see.

I have a spare Asus Xonar DX PCI Express card lying around, so I'll give that a test also as soon as I have the chance.


Edit: Table in first post updated.
« Last Edit: October 25, 2013, 05:38:27 am by Dr.Venom »

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #17 on: October 25, 2013, 11:27:36 am »
Asus Xonar DG | PCI | Win7x64
VIA VT1828S | On-Board | Win7x64
Realtek ALC889 | On-Board | Win7x64
Realtek ALC861 | On-Board | WinVistax64
« Last Edit: October 26, 2013, 05:02:39 am by SMMM »

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #18 on: October 25, 2013, 12:04:55 pm »
HERE'S something interesting!  Check out the results I got from my Nvidia 550ti - video and audio through HDMI out.  PCI Express, Win7x64
« Last Edit: October 25, 2013, 12:07:29 pm by SMMM »

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #19 on: October 27, 2013, 05:19:49 am »
Hi SMMM,

Thanks for adding all of your results. The Nvidia one is certainly interesting.

With regards to the results of the Asus Xonar DG, VIA VT1828S and Realtek ALC889, could you verify that in each separate test for these devices you ran through step 1 (from the first post)? I.e. that for each individual test the to be tested audio device was (re)set to be a) the default audio device and b) the sample rate of the device was set to "16 bit, 48000Hz (DVD Quality)", as shown in below pictures, before doing the test?

It's important that this is done correctly for each separate device, otherwise FreqTest will give false results. So I'd rather have it doublechecked, to be really sure the (unstable) results for these three devices are correct.




SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #20 on: October 27, 2013, 07:35:19 am »
Yessir.  Did exactly that for each that I tested.  Set each as default device, 16-bit/48000hz, disabled all other sound devices.  The Realtek ALC889 is from a similar motherboard to that of JDFan's, I'm thinking.  It's a super cheap Gigabyte board I got for free in a processor/combo combo deal - worth about $40 brand new, lol.

Also, you typed the results for the Realtek ALC861   wrong in the opening post.  Should be much higher on the list.  :D
« Last Edit: October 27, 2013, 07:38:14 am by SMMM »

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #21 on: October 27, 2013, 03:18:49 pm »
Yessir.  Did exactly that for each that I tested.  Set each as default device, 16-bit/48000hz, disabled all other sound devices.  The Realtek ALC889 is from a similar motherboard to that of JDFan's, I'm thinking.  It's a super cheap Gigabyte board I got for free in a processor/combo combo deal - worth about $40 brand new, lol.

Great, thanks for confirming.

Is there a possibility that you could also test the ALC861 while running on Win7 and/or XP? Just in case you're running it in a multiboot environment already. Calamity's results for the Sigmatel showed that it may impact how close it comes to 48Khz, even though not impacting the variability. It would be interesting to know -if- and by how much the results would differ between the different OS's for this quite stable / accurate chip.

Quote
Also, you typed the results for the Realtek ALC861   wrong in the opening post.  Should be much higher on the list.  :D

Ah, no I didn't. The sort was based on "Max minus Min".  The idea being that the lower this "max minus min" value, the better you can/could address the "average" deviation in software. So something like 47997.000 with -no- variation would then actually be preferable to something like 48000.14 with -some- (however small) variation. But since we don't have any such patch in MAME, or will there be I guess, it's kind of moot sorting criterium.

 I've changed it to a new "Max plus Min" sorting criterium, where for both Max and Min the absolute deviations from 48Khz are now taken. I think you'll like the resulting "ranking" better ;)
« Last Edit: October 27, 2013, 03:22:33 pm by Dr.Venom »

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #22 on: October 27, 2013, 11:55:11 pm »
Gotcha.  I like the new organization of the list, but I was talking about the numbers.  You have

48000,180   48000,300   48000,800

When they should be

48000,018   48000,030   48000,080

And the comp it's on is actually my file server PC running Server 2008 (a slightly modified version of Vista, using Vista drivers), so not much I can do to test it with XP and Win7 at the moment.
« Last Edit: October 27, 2013, 11:58:28 pm by SMMM »

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #23 on: October 28, 2013, 11:37:37 am »
I see, missed that one. I guess that's why I prefer copy & paste  :D. I've updated the table with the correct numbers.

Out of interest, what manufacturer and model is the mainboard that contains the ALC861?  I'm thinking that maybe I should add a column for the motherboards used, possibly that'll provide us a clue to the accuracy / stability of the sound devices in general.

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #24 on: October 28, 2013, 02:22:48 pm »
Card | Motherboard

Realtek ALC861 | Acer MCP61SM-AM
VIA VT1828S | MSI 870-G45
Realtek ALC889 | Gigabyte GA-78LMT-S2P

krick

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2008
  • Last login:December 23, 2020, 12:54:14 pm
  • Gotta have blue hair.
Re: Soundcard frequency stability test - please add your results
« Reply #25 on: November 03, 2013, 01:53:16 am »
PCI Sound Blaster X-Fi XtremeGamer on Windows XP x64

Sound Blaster X-Fi XtremeGamer   47,998.995   47,999.050   47,999.099   XP x64   PCI   Krick

If my calculations are correct, this is the new #2 card in your table.
« Last Edit: November 03, 2013, 02:51:22 am by krick »
Hantarex Polo 15KHz
Sapphire Radeon HD 7750 2GB (GCN)
GroovyMAME 0.197.017h_d3d9ex
CRT Emudriver & CRT Tools 2.0 beta 13 (Crimson 16.2.1 for GCN cards)
Windows 7 Home Premium 64-bit
Intel Core i7-4790K @ 4.8GHz
ASUS Z87M-PLUS Motherboard

krick

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2008
  • Last login:December 23, 2020, 12:54:14 pm
  • Gotta have blue hair.
Re: Soundcard frequency stability test - please add your results
« Reply #26 on: November 03, 2013, 02:09:50 am »
Onboard Realtek ALC887 (ASUS P8Z77-M motherboard) on Windows 7 x64

Realtek ALC887   47,997.927   47,997.951   47,997.971   W7 x64   On-board   Krick
« Last Edit: November 03, 2013, 02:42:20 am by krick »
Hantarex Polo 15KHz
Sapphire Radeon HD 7750 2GB (GCN)
GroovyMAME 0.197.017h_d3d9ex
CRT Emudriver & CRT Tools 2.0 beta 13 (Crimson 16.2.1 for GCN cards)
Windows 7 Home Premium 64-bit
Intel Core i7-4790K @ 4.8GHz
ASUS Z87M-PLUS Motherboard

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #27 on: November 03, 2013, 03:35:01 am »
PCI Sound Blaster X-Fi XtremeGamer on Windows XP x64

Sound Blaster X-Fi XtremeGamer   47,998.995   47,999.050   47,999.099   XP x64   PCI   Krick

If my calculations are correct, this is the new #2 card in your table.

Neat!  Is this it?

http://us.store.creative.com/Sound-Blaster-XFi-XtremeGamer/M/B000J1F1BI.htm

krick

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2008
  • Last login:December 23, 2020, 12:54:14 pm
  • Gotta have blue hair.
Re: Soundcard frequency stability test - please add your results
« Reply #28 on: November 03, 2013, 09:26:15 pm »
Yep.  I actually have two of those cards, but one doesn't work right.

One came with a low-profile bracket and has a serial number containing: "SB0730"
The other has a full-height bracket and has a serial number containing: "SB073A"

The only one that works is the "SB073A".  I think the other one is an older hardware revision that had issues.

Instead of using the CD that ships with the card, I recommend using one of these driver/software packs...

    SB X-Fi series Support Pack 2.5 (10/25/2011)
    http://forums.creative.com/showthread.php?t=587995

    SB X-Fi Series AuzenForte Pack 2.0 (12/27/2012) based on the official Win 8 Auzen Forte driver
    http://forums.creative.com/showthread.php?t=699146

I'm using the AuzenForte Pack 2.0 with my card.
Hantarex Polo 15KHz
Sapphire Radeon HD 7750 2GB (GCN)
GroovyMAME 0.197.017h_d3d9ex
CRT Emudriver & CRT Tools 2.0 beta 13 (Crimson 16.2.1 for GCN cards)
Windows 7 Home Premium 64-bit
Intel Core i7-4790K @ 4.8GHz
ASUS Z87M-PLUS Motherboard

Goglu2

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 10
  • Last login:August 21, 2019, 03:09:33 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #29 on: November 03, 2013, 10:13:31 pm »
Auzentech X-Fi Prelude 7.1 | PCI | WInXP 32Bit

Min. 47998.720Hz  Avg. 47998.810Hz  Max. 47998.897

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #30 on: November 04, 2013, 04:55:57 am »
Hi Krick and Goglu2,

Thanks for adding your results, I've updated the main table in the first post. I'm getting quite puzzled as to the common denominator to stability. Anyone with an educated guess? 

I guess to get a sense of whether it's the card or something else we would need verification of the currently tested cards by other users / in different setups. So if anyone has one of the already tested cards, please run the test with your setup (it'll only take you a minute) and let us know the results!

We do have to note that the FreqTest test is a DirectSound test afaik. This is relevant for the current MAME implementation, but it doesn't necessarily say something about other audio (low-latency) API's, like WASAPI-EX or ASIO. Of course this is irrelevant as long as MAME doesn't have such an implementation, but at least we can hope. At which time we would need a FreqTest program which can also work with these APIs, and revisit these tests. I guess that could lead lead to different result for the various cards.  In case anyone with proficient programming skill and MAME knowledge would be interested in the low latency API's, here are the links for possibly the "easiest" and most compatible way of implementing those:

PortAudio - An Open-Source Cross-Platform Audio API: http://www.portaudio.com/
ASIO4ALL - Universal ASIO Driver For WDM Audio: http://www.asio4all.com/



Calamity

  • Moderator
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 7076
  • Last login:Today at 11:26:35 am
  • Quote me with care
Re: Soundcard frequency stability test - please add your results
« Reply #31 on: November 04, 2013, 07:54:59 am »
Hi Dr.Venom,

Just to clarify, did you get good evidence when testing in your system that better results in FreqTest mean better sound "smoothness" in MAME (less buffer underruns/overflows)? I'm assuming the answer is yes.

This is way beyond my knowledge of things, but it would be interesting to find if the PCI port, IRQs, etc. have some role to play here too, so that there could be some room for tweaking from the BIOS side.
Important note: posts reporting GM issues without a log will be IGNORED.
Steps to create a log:
 - From command line, run: groovymame.exe -v romname >romname.txt
 - Attach resulting romname.txt file to your post, instead or pasting it.

CRT Emudriver, VMMaker & Arcade OSD downloads, documentation and discussion:  Eiusdemmodi

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #32 on: November 04, 2013, 10:55:04 am »
Hi Calamity,

Just to clarify, did you get good evidence when testing in your system that better results in FreqTest mean better sound "smoothness" in MAME (less buffer underruns/overflows)? I'm assuming the answer is yes.

It depends on what you call "good" evidence. I guess you remember the thread where we spoke about a patch that enables a higher granularity for the audio latency setting? The one that enables the audio latency setting to be set in increments of 0.1 (in windows the audio latency setting is directly related to the size of the soundbuffer, which is set according to the size of the audio latency setting in mame.ini). See here: http://forum.arcadecontrols.com/index.php?topic=130944.0.

Given the use of that patch I noticed that with both my X-Fi cards I could only lower the sound_latency to 1.7 when using GroovyUME and the MESS MSX2 driver with Konami SCC games (these games contain more than one emulated soundchip) before there would be -NO- buffer over/-underruns at all when running the emulation for half an hour. The criterium was no over- or underruns at all. Then I tried the on-board Realtek and to my surprise I could lower the setting to 1.3 to get -no- buffer over-/underruns at all when running the same setup for half an hour. At first I though the default buffer sizes (that I'm logging in my personal build) for both chips differed, such that the settings would not be comparable. But they were the same. Then I got the idea to try the FreqTest on both chips, and these showed these large differences in stability (see the main table and explanation in first post).

So I could have lower -stable- soundsetting with the Realtek chip than the X-Fi's -AND- the Realtek chip showed a much more stable frequency stability result with FreqTest. Adding these two results together implied to me that they are related, and that's what made me post about it. That said, we could only be really sure if we had some professional test equipment to scientifically prove there's a latency difference between the two. So I guess the usual disclaimers apply.

In case there is a real relationship, my theory would be that MAME resamples all audio that the emulation core is generating to 48000Khz. So you have 48000 samples per second. Now if a soundcard would randomly play that stream at a rate between e.g. 47997 and say 48045 than it could easily starve the soundbuffer, thus resulting in sound synchronization problems. That would be my theory at least, for what its worth. Maybe Im completely wrong about all this.

Quote
This is way beyond my knowledge of things, but it would be interesting to find if the PCI port, IRQs, etc. have some role to play here too, so that there could be some room for tweaking from the BIOS side.

It's also way beyond my knowledge. There's one thing that I noticed though: PCI and PCI-Express are two entirely different beasts from a hardware point of view, so don't get fooled by them sharing the PCI acronym. So where for PCI you could adjust the "PCI-Latency" timer value in the bios, thus configuring how many cycles each PCI device gets before handing over to the next device in the system, this is not the case anymore for PCI-Express. PCI-Express is packet based from what I understand, but what the implications are for soundcards and sound card drivers is way beyond my understanding.

I've been looking in the bios of my Asus P8Z77V (which *only* has PCI-Express slots) but there's seems nothing to configure anymore for PCI-related devices, apart from whether you'd want a specific video card slot to work at x16 or x8, which only seems relevant if you have a setup with more that one videocard.

Also I have to note that the XFi cards are giving me very good results (much better than DSound) with ASIO (via ASIO4ALL) in WinUAE, with no noticable difference stability wise with the realtek chip (apart from the XFi cards sounding richer to me).

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #33 on: November 05, 2013, 10:10:08 pm »
Related question: What determines the refresh rate stability?  Is it the video card or the display itself?  What would the 'benefits' of having a more stable refresh rate be, if any?

SMMM

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 21
  • Last login:October 10, 2020, 09:19:13 pm
Re: Soundcard frequency stability test - please add your results
« Reply #34 on: November 11, 2013, 02:37:28 am »
Is there a way we can introduce this test to a wider audience?  I'm about ready to pull the trigger on buying a soundcard for my project, but am uncomfortable doing so - having a larger sample size with more examples would be excellent.

Dr.Venom

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 270
  • Last login:May 08, 2018, 05:06:54 am
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #35 on: November 14, 2013, 05:24:11 am »
Related question: What determines the refresh rate stability?  Is it the video card or the display itself?  What would the 'benefits' of having a more stable refresh rate be, if any?

I wouldn't worry about the refresh rate stability of your videocard / monitor, it's generally stable enough. If you do the math you'll see that any variation is in the nanoseconds per second, so it will take longer  for any possible deviation to accumulate to the stage where it would interfere with the emulation, then you are able to keep awake ;).

If there would be any sort of "problem" it's regarding the granularity of modern day video cards. They seem to work with multipliers that allow for high granularity, but not the infinite granularity that is needed to re-create the exact timings of all possible real arcade hardware. It comes very close in most cases (close enough to do "very accurate" emulation), but it's not perfect. Calamity called this a problem of A) Dotclock granularity and B) Dotclock uncertainty. If you're interested in some more technical background you can read more about it here: Theoretical versus real refresh rates

Is there a way we can introduce this test to a wider audience?  I'm about ready to pull the trigger on buying a soundcard for my project, but am uncomfortable doing so - having a larger sample size with more examples would be excellent.

Yes, basically we would need some other people to confirm Krick's results for the "PCI Sound Blaster X-Fi XtremeGamer", and generally get more conformation from other users on the already tested cards in the table. Hopefully some more people will add their results.

That said, I think we should keep in mind that we don't know the exact cause for the variation, and it may well have to do with how the DirectSound API is routed in Windows. There are much better APIs out there these days, like X-Audio2, WASAPI-EX and ASIO, which all are able to provide audio with much lower lag than DSound and as such would be better suited to (Groovy)MAME. The exclusive mode API's are even able to get close to realtime audio, whereas DSOUND isn't able to get better than something in the range of ~ 3 frames of lag (if not worse). Once a move in the direction of these new APIs is taken, I would't be surprised if the results for all tested soundcards would be quite different. (Of course we would also need an updated FreqTest tool to work with the new APIs). But until then, I think it will be anybody's guess... As such any educated guesses on this topic are still welcome :)

Zagi

  • Trade Count: (0)
  • Newbie
  • *
  • Offline Offline
  • Posts: 1
  • Last login:May 23, 2014, 05:19:26 pm
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #36 on: January 14, 2014, 09:52:37 pm »
Is it proven the frequency stability have an impact on the latency ? I know this is about mame but in the built in ggpo emulator (fba) I can only set the sound buffer down to 3 frames without cracking with the Sound Blaster Live CT4760 which is not the most stable card I have tested.

I can also attest that the whole configuration may have an impact on the latency, as with my old rig for my cab (DFI nf4 ultra-d, opteron 165, 2gb of DDR1) I could lower the latency to 3 frames on the audigy 2 value, but I can't go below 4 frames with the new one (Asus p5kc, Q6600, 4gb of DDR3)

Anyway here are my results :

ALC883 XP64
ALC892 8.1 64
Sound Blaster Live CT4760 XP64
Audigy 2 Value XP64



boganslogan

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 2
  • Last login:August 19, 2014, 12:17:19 pm
  • I want to build my own arcade controls!
Re: Soundcard frequency stability test - please add your results
« Reply #37 on: June 12, 2014, 09:53:09 am »
I just tested my Creative Soundblaster Titanium HD in Windows 7 x64 and I got wonky results. I run an optical cable using DTS Connect from my sound card to my Logitech Z-5500 control panel. Unlike the other X-Fi or Soundblaster audio tests people submitted, I tested each of the 3 modes: Game, Audio Creation, and Entertainment. Audio Creation Mode is supposed to be the lowest latency with bit-matched playback and recording. I'm going to just leave the file names as-is which will tell you what I enabled or disabled with each test.

The wonky part is test #2 and test #7 had the exact same settings but I got different results, so that's why I think something's amiss.
« Last Edit: June 12, 2014, 09:56:34 am by boganslogan »

machyavel

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 67
  • Last login:December 25, 2016, 10:23:52 am
Re: Soundcard frequency stability test - please add your results
« Reply #38 on: June 12, 2014, 02:51:43 pm »
W7x64, PCI card ESI JULI@:

vicosku

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 107
  • Last login:November 25, 2020, 10:02:52 am
Re: Soundcard frequency stability test - please add your results
« Reply #39 on: June 18, 2014, 12:08:46 pm »
Here are my results, from worst to best.  The venerable $30 USB Behringer UCA202 performed well, as I expected.  All tests were performed on the same machine running XP64.

Realtek ALC888 | Onboard
Asus Xonar DG | PCI
HDE CMedia | USB
Turtle Beach Audio Advantage Micro II | USB
Behringer UCA202 | USB

« Last Edit: June 18, 2014, 12:13:18 pm by vicosku »