XXHighEnd

Ultimate Audio Playback => Playback Tweaks and Source related subjects => Topic started by: blaine78 on April 03, 2011, 05:18:08 am



Title: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 05:18:08 am
Hi,
Found a tweak for people who use USB audio devices, using the Windows own generic USB audio driver.
Increasing the buffer of the driver seems to have a great impact on sound for me using an Ayre QB-9 DAC. Sound seems soother, less grit. I'm using Windows 7 SP1 64bit, this will also Work for vista 32 and 64.

To set the registry entry:
Open Registry Editor. Locate and then right-click the following registry subkey:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Enum\USB\VID_<xxxx>&PID_<yyyy>&<??_??>\<look for ALL device instances with DeviceDesc:  USB Audio Device mentioned>\Device Parameters

in Device Parameter folder right click, DWORD (32-bit) Value. Rename to CapturePacketsPerUrb, and then press ENTER.

Right-click CapturePacketsPerUrb, and then click Modify.
In the Value data box, type in 10. 10 = 10ms buffer, you can choose between 3 - 10 ms. 10ms worked best for me.
you must restart your PC after adding this registry setting

Happy listening.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 08:44:56 am
Ehm, Blaine ... I am sorry, but you are "applying" general tweaks here to an application which tweaks itself, or won't let itself be tweaked otherwise (meaning : these things can work out very counter productive).

Besides that, I am sure you didn't test the real merits of this (I did), and you will not be able to tell how it works, what actually works, and what will be damaged by it. It is not even about the "buffer length" as such.

OF COURSE everybody can do what he wants, but it is not advised, and a few of us in here already know what may be the result : A PC won't behave as anticipated upon and you won't get it right anymore either. And hey, didn't we see you re-installing W7 SP1 for the nth time to be sure about this and that and whatever it is you won't know yourself ? this is exactly about these kind of things. For example, did you ever investigate what it means to apply this tweak to "all instances" as you propose it ? Well, you propose nothing, but copied it from the 1000 places elsewhere, and forgot to dig up that one place (if it exists) which tells what you will actually be doing to which.
DON'T.

Or :

Go ahead to tweak your JR to dead, while in here we try to tweak the OS to dead. That's another thing you know.

Nevertheless your advise is appreciated, as will all your next and those from others. But we really like to have them checked for their real merits which plainly and clearly is not for everyone. Not that this is a (forum) rule or anything, but 99% of these things work out for the worse. Never mind your QB-9 benefits from it. But remember, this is XXHighEnd full of tweaks and not a random other player without any.

To make it hopefully clear the best, you will remember me saying (elsewhere) that WASAPI is not to stutter or anything in any event, and that at least in here (this forum) you won't find any one post about such a thing (but one, which was about a malfunctioning laptop), while "overthere" (other forum, other player(s)), in fact all complained about this. I hope that you will get from this that chances are not large that any so called "tweak" necessary for another player, are needed for the one we use in here. This means it can only be dangerous. Now, use XXHighEnd (and I'm really not telling you to do so !) and all is different. Hopefully you won't recognize your QB-9 anymore in the first place (to the good sense), but which happens exactly because of the hundreds of these little and larger things ("tweaks") which already are in the software.

Let's finish this little post by pointing out that many of the "tweaks" in XXHighEnd emerged from posts from all of you. This is why it's *always* appreciated to come up with something which maybe is unknown so far. Just be careful about what it really will do. And otherwise I'll be here to write posts like this. It happened before. :)

Thanks,
Peter


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 09:06:20 am
Hi Pete,
This tweak is as stated above, a tweak for USB Audio Devices, NOT software audio players. The tweak is to raise the data buffer in the USB AUDIO DEVICE. it is not about stutter as i had no stutter previously. Is for Audio quality and works wonders here, REGARDLESS of the playback software. Is a tweak for others to try out. There is no harm, and is not dangerous. if it doesn't work for some, just delete the registry entry. :)


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 09:31:25 am
Hi Blaine,

I realize my english is not the best, but my text about the stuttering was an example.

Quote
This tweak is as stated above, a tweak for USB Audio Devices, NOT software audio players.

Well, then you just as well may think that a whole PC is not related to audio. But it exactly prooves what I was saying : you think like you think, and I think you think wrongly. Of course this affects audio players ? what do you think ?!
And since you are as far that W7 SP1 may sound better, what do you think this comes from ? The OS is LOADED which sh*t like this, and it all influences sound.

If you won't believe this, go ahead. It is your PC !


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 09:42:19 am
Once again, it is NOT tweaking an audio players code, is for USB AUDIO DEVICE which can/will influence the final sound, as with IRQ settings, USB IdleEnable, and Clock Resuloution. this is another tweak. Pete, and others, if it doesn't work for you, don't use it, at least try it out first then decide. As for this tweak being dug up from a 1000 places, i seem to only find it at one place, Microsoft website. try and google and see if a 1000 posts pop up, then tell me.

and yes, an OS is loaded with s*it like this, been building my own computers for 10 years now, with audio related hardware and software.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 11:00:40 am
I will give the subject a twist and see how far we come with this. Be ready to burst in tears, okay ? I am ready for that too. :)

Btw, you don't have to coorporate if you don't like to, or have better things to do otherwise. But if you don't, you loose in advance because of not showing up in court. Notice that I loose rarely in these kind of games (which I just made out of it), but it sure can happen. As said, I am prepared for that.

Now let's see. Below you see my Google result. Not exactly 1000, but 650 only. However, this has been one means only to look for it, and there are others. Not sure if I can make it to exactly 1000, but let's say 650 is enough for now. :yes:

Next, you are going to provide me that "Microsoft" link you referred to, and because we can't be sure what I am going to see from that (because of countries directing to certain MS mages) you are also going to make a screen copy of the contents. So, both please.

Then, you are going to tell in here - whatever it is you think you found - what it actually does. And what it is for. Of course this should equal your earlier description, but you are allowed to deviate from that.

When you have done this, I will be back with some comments. This could comprise of "I lost" only. But maybe not. This is actually up to you and what you come up with.

Small hint : Google again what you Googled for before, and notice Phasure.com to be on top. It may tell you something.

Have fun !
Peter


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: Gerard on April 03, 2011, 11:35:10 am
 :yahoo: A Contest :yahoo:

 ;)


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 11:56:40 am
I will give the subject a twist and see how far we come with this. Be ready to burst in tears, okay ? I am ready for that too. :)

Btw, you don't have to coorporate if you don't like to, or have better things to do otherwise. But if you don't, you loose in advance because of not showing up in court. Notice that I loose rarely in these kind of games (which I just made out of it), but it sure can happen. As said, I am prepared for that.

Now let's see. Below you see my Google result. Not exactly 1000, but 650 only. However, this has been one means only to look for it, and there are others. Not sure if I can make it to exactly 1000, but let's say 650 is enough for now. :yes:

Next, you are going to provide me that "Microsoft" link you referred to, and because we can't be sure what I am going to see from that (because of countries directing to certain MS mages) you are also going to make a screen copy of the contents. So, both please.

Then, you are going to tell in here - whatever it is you think you found - what it actually does. And what it is for. Of course this should equal your earlier description, but you are allowed to deviate from that.

When you have done this, I will be back with some comments. This could comprise of "I lost" only. But maybe not. This is actually up to you and what you come up with.

Small hint : Google again what you Googled for before, and notice Phasure.com to be on top. It may tell you something.

Have fun !
Peter

Hi Pete search on exact phrase CapturePacketsPerUrb, which is what i'm specifically talking about here, 10 replies on google, and only 1 that has proper information, Microsoft site.
Thanks for playing. need a tissue? :)
And regards to what i found and what it's for, i mention on very first post.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 12:33:53 pm
Yes, you need a tissue. Well, for now. :)
Where are your links ? where is your copied page ?

Instead of tissues, maybe look this this : :blush1:
haha


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 12:44:18 pm
Yes, you need a tissue. Well, for now. :)
Where are your links ? where is your copied page ?

Instead of tissues, maybe look this this : :blush1:
haha
I need a tissue?? nah, you do  :)
this is the Microsoft link
http://support.microsoft.com/kb/953228

Not all the information is relevant on this above link as it's speaking of correcting other issues regarding UBS 2 audio, but the buffer still works for USB 1 Audio devices. Scroll down to the information regarding changing the Buffer size registry  edit of the USB device. I tried it, cause i can't help myself when a computer audio tweak is involved. fortunately it sounded great.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 12:47:59 pm
Can't you make screencopies ?
:blush1::blush1::blush1::blush1:

I can.

By now dutch people will know you have lost.
Now you ... ;)



Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 12:52:25 pm
Can't you make screencopies ?
:blush1::blush1::blush1::blush1:

I can.

By now dutch people will know you have lost.
Now you ... ;)


Umm, you haven't captured the info i was talking about in this screen shot. maybe post the full facts about the buffer tweak.
I have won this contest. i said there was only 10 results in google using exact phrase, and have a link to the MS site. what's your point Pete? It's a USB Audio buffer tweak? i don't get what you are on about? It works, and soudns good. i said ignor other info on the MS site as it's not relvant, only the buffer tweak that is of interest. now hang your head in shame! :teasing:


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 12:53:56 pm
... not yet ... :)


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 01:15:29 pm
Quote
and because we can't be sure what I am going to see from that (because of countries directing to certain MS mages) you are also going to make a screen copy of the contents.

Didn't you read this ? or did you maybe don't want to read it ?

Don't be too ignorant on this. I clearly said it for a reason.

Btw, if you want to attach a screen copy, just click on the "Additional Options" you see in the below left corner during posting.

I'll allow you not to have lost yet ...


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 01:21:48 pm
Quote
and because we can't be sure what I am going to see from that (because of countries directing to certain MS mages) you are also going to make a screen copy of the contents.

Didn't you read this ? or did you maybe don't want to read it ?

Don't be too ignorant on this. I clearly said it for a reason.

Btw, if you want to attach a screen copy, just click on the "Additional Options" you see in the below left corner during posting.

I'll allow you not to have lost yet ...
Ah, good, found how to attach.. here it is. this is the info on how to change the buffer. and once again, not all info is relevant (hotfix etc etc)

()


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: manisandher on April 03, 2011, 01:26:48 pm
I have nothing really to contribute to this thread other than... only a brave man/woman would take Peter on when it comes to computer audio.

Those of us who've been here for a while have seen many 'contenders' come and go, all defeated IMO.

But there's always a first!

Mani.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 02:11:50 pm
At last ...
Btw, here's the one and only official link, for others in other countries : http://support.microsoft.com/kb/953228/en-us

Now to the point again;
Since this is a patch to a misbehaving system, which includes a new version of some usb**.sys file, you won't be knowing whether it works without this file. It may, but it just as well may not, and therefore you have to proove it (somehow).
The *fact* that there's exactly no real reference to this "KB" anywhere, tells me (theoretically !) that it doesn't exist. The link I mentioned though, *is* real, but it isn't for any other country or language. Notice that all the others (650) are stupid auto translations, and the "standard" link you provided will in no way lead to the english text. This tells me not all, but something.
For me this goes as far as that this is some leftover from MS and possibly some "accident" in the first place. Btw, the patch can be downloaded just the same, but you won't be able to tell to what (OS version) it should be applied (because the data given is not consistent regarding this).
We could think that by now it is an official thing (from off Vista-SP2 or something but this is the inconsistent data, or otherwise at least for W7 RTM and W2008 R2.
Sadly (for you) the Registry Attribute is not there by default, while it defaults to 10ms, which is what you set it to, and now you have better sound.
GREAT.
But if you don't mind, I won't believe that. You should at least have set it to *other* than 10ms to have things in your favour. And then still we won't know.

Of course we now are believed to think that the default has changed since whenever this came about (2007 I think), and that is why it works for you. But even more "of course" I won't believe any of such a thing, especially because you are not the first to come up with something like this, and the most often people just don't know what it is about, but read something somewhere. This is similar to what you call a buffer length in time, while it is not at all (yes I know, you see ms).

Here you have a few other links to play with. Can't find the registry entries but somewhere they exist (in 1000 other links :)). It's about a similar thing and most probably the registry key is the same, but the attribute name is different (if memory serves me well). Just apply it to your USB (DAC) device ...

http://www.soldierx.com/tutorials/USB-ControllerAdapter-polling-rate-tweaking
http://forums.epicgames.com/showthread.php?t=581256
http://www.ngohq.com/news/15043-how-to-increase-usb-sample-rate-in-windows-vista-7-a.html

All I want to say with these links at hand : there is more that acts upon the same thing, and while we won't even know which has prevalence, we also don't know whether things could be made inconsistent because of this. And THAT is what I am about.
What next will happen is that 80% of people have audio stuttering or whatever at a next XX version, while 0% of those people will come up with a "hey, I applied that link from Blaine !". No no, that is for me to find out.

Do you now get my message ?
Nobody won, but you lost. Almost.

Still ...
Still it was smart of you to find this KB, because I sure don't see how ever you could get there. Also, the "tweak" itself most clearly is totally unknown (ok, not anymore  :)). So, it sure might do something, and it is to be investigated at some stage. But this is very different than just applying it, without knowing what it will cause to others. I know, you may not care much, but as sufficiently said / implied by now, I do. I have a player to support and I don't want users to end up with "stuttering" all over, just because something by accident worked for you. That is why I gave that WASAPI example right away, but apparently it needed quite some more posts to make that clear to you. Well, maybe it doesn't still.

Also notice (for some mindsetting perhaps) that actually no such thing exists as a "device buffer" which would be able to change for USB devices. The USB devices themselves have these buffers, BUT in the OS these buffers exist just the same. And oh, for XP it is "1ms" (which again is no ms at all).
This link of yours may be able to change that, and back at the time I would have been the most happy with that. But since I didn't know about this link, I solved it differently.
Hey, what did I just say ?
Ah, oh. Now what.

So, good link, and you didn't loose either just because of that. Nobody wins, nobody looses, just don't get lost in counterproductive tweaks you won't recall yourself when things stop working.

Eh, thanks ? :)


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 02:58:59 pm

Sadly (for you) the Registry Attribute is not there by default, while it defaults to 10ms, which is what you set it to, and now you have better sound.
GREAT.
But if you don't mind, I won't believe that. You should at least have set it to *other* than 10ms to have things in your favour. And then still we won't know.

Pete, please read carefully what i posted from MS site.
The default for XP is 10ms and 4ms for Vista. Unknown for Win 7. you ,yourself are guessing. i don't use XP, i use win 7. it is only defaulted to 10ms after installing a patch, which i have not done and this patch is for vista not win7.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 03, 2011, 03:01:45 pm

http://www.soldierx.com/tutorials/USB-ControllerAdapter-polling-rate-tweaking
http://forums.epicgames.com/showthread.php?t=581256
http://www.ngohq.com/news/15043-how-to-increase-usb-sample-rate-in-windows-vista-7-a.html



Thanks, i've already seen these links before, and didn't work. USB IdleEnable that another posted on here does work.


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: PeterSt on April 03, 2011, 04:14:17 pm
Quote
you ,yourself are guessing.

Haha, careful now. You are the guessing one, and I *know*.

Default (actually fixed as far as I know or knew) for XP is 1ms (which is not ms), for Vista I forgot whether I ever tested that, and for W7 it is infinity. I am GUESSING that for Vista it's infinity too.

Remember, I can see, measure, try, write code to try, write the audio software anyway.
So who is guessing ? not me.

Maybe your means of interpretation are different from mine, but really nothing like entering a new Registry entry will apply a "patch". This is to be read as : without applying that patch you can add Registry entries you want, but nothing will happen. So, it needs the patch first.
Next, the patch disappears, and instead it becomes a standard for the next OS version. This will include W7, unless it's taken out again anyway. Now which way do you want to go ? ... Taken out ? then it does nothing. Still in there ? then it defaults to 10ms and can next (and only now) be overwritten.
If you want to read this differently, all stops here.

What it (once again) all leads to, is that you won't know what you are doing; not because your are dumn or anything, but because you can't know what the OS does for - or to you. Remember, I *know* how it is, because I check things.

Now think further ... this beautiful tweak of yours could change your infinity into 10ms. So, you applied a change indeed. Sadly, XXHighEnd can (and will) work with this infinity figure. Now what ? You molested things.
I am not saying this *is* so, but chances are fair, if only your "tweak" still works.

Shall we now cut it out ? apply it to JR and be happy.

I will tell you one last thing, to maybe show you at last that you don't know what you are doing ("to");
Try to find latency figures from MS. This is how fast a response from buffers etc. can be, and what the best response for e.g. MIDI stuff can be.
What will you find ? 10ms.
You already know by now this actually can be 0.5ms, right ?
Or do you maybe accept that it is really (but now REALLY because *I* say so) is 1 stereo sample of 32/384 ? take your calculator. And not only because I say so, but because people use it (to be honest at 192KHz).
You want to project it onto external latency ? also fine. Multiply what you found by 48. Or by 32 for those with (RME) soundcards which can do that.
Remember, 32/384, may you get around what that actually says (referring again to your "1ms" which is not about time at all).

Now tell me again what you'd want with your xxms which I overrule beyond all MS articles.
Yeah, that you can molest your own PC with it, because I'm really not in control of everything (especially the "tweaks" I don't know about).

I really hope this is enough of it ! :)


Title: Re: USB Audio Driver Registry Buffer tweak
Post by: blaine78 on April 04, 2011, 12:39:22 pm
Quote
you ,yourself are guessing.

Haha, careful now. You are the guessing one, and I *know*.

Default (actually fixed as far as I know or knew) for XP is 1ms (which is not ms), for Vista I forgot whether I ever tested that, and for W7 it is infinity. I am GUESSING that for Vista it's infinity too.

Remember, I can see, measure, try, write code to try, write the audio software anyway.
So who is guessing ? not me.

Maybe your means of interpretation are different from mine, but really nothing like entering a new Registry entry will apply a "patch". This is to be read as : without applying that patch you can add Registry entries you want, but nothing will happen. So, it needs the patch first.
Next, the patch disappears, and instead it becomes a standard for the next OS version. This will include W7, unless it's taken out again anyway. Now which way do you want to go ? ... Taken out ? then it does nothing. Still in there ? then it defaults to 10ms and can next (and only now) be overwritten.
If you want to read this differently, all stops here.

What it (once again) all leads to, is that you won't know what you are doing; not because your are dumn or anything, but because you can't know what the OS does for - or to you. Remember, I *know* how it is, because I check things.

Now think further ... this beautiful tweak of yours could change your infinity into 10ms. So, you applied a change indeed. Sadly, XXHighEnd can (and will) work with this infinity figure. Now what ? You molested things.
I am not saying this *is* so, but chances are fair, if only your "tweak" still works.

Shall we now cut it out ? apply it to JR and be happy.

I will tell you one last thing, to maybe show you at last that you don't know what you are doing ("to");
Try to find latency figures from MS. This is how fast a response from buffers etc. can be, and what the best response for e.g. MIDI stuff can be.
What will you find ? 10ms.
You already know by now this actually can be 0.5ms, right ?
Or do you maybe accept that it is really (but now REALLY because *I* say so) is 1 stereo sample of 32/384 ? take your calculator. And not only because I say so, but because people use it (to be honest at 192KHz).
You want to project it onto external latency ? also fine. Multiply what you found by 48. Or by 32 for those with (RME) soundcards which can do that.
Remember, 32/384, may you get around what that actually says (referring again to your "1ms" which is not about time at all).

Now tell me again what you'd want with your xxms which I overrule beyond all MS articles.
Yeah, that you can molest your own PC with it, because I'm really not in control of everything (especially the "tweaks" I don't know about).

I really hope this is enough of it ! :)


All that matters Pete, is that it sounds better.