HydrogenAudio

Hosted Forums => foobar2000 => Support - (fb2k) => Topic started by: andy_c on 2008-03-25 17:08:32

Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: andy_c on 2008-03-25 17:08:32
Hi,

I've been having a problem with Foobar 0.9.5 "forgetting" the ASIO config for my E-MU 0404 USB sound device when I shut down the system.  I'm using the E-MU as a USB-to-S/PDIF converter to drive an external DAC.  For whatever reason, S/PDIF only works with the E-MU 0404 USB when ASIO is used.

When I go into the ASIO virtual device editor, it looks like this initially:

ANALOG OUT 32-bit Left
ANALOG OUT 32-bit Right
S/PDIF OUT 32-bit <none>
S/PDIF OUT 32-bit <none>

I then change it to:

ANALOG OUT 32-bit <none>
ANALOG OUT 32-bit <none>
S/PDIF OUT 32-bit Left
S/PDIF OUT 32-bit Right

Then, in "output device" I choose "ASIO: ASIO E-MU 0404 | USB", and click the "Save All" button.  This works fine, just as expected.  I can play all supported files just fine.

Next, I reboot and try to use Foobar with this saved ASIO configuration.  When I try to play a file, I get the message "Unrecoverable playback error:  Requested ASIO driver not found".  To fix this, I must  go into the ASIO virtual device config and choose "Remove" for the displayed E-MU 0404 USB.  Before removal, the text of the device name is still shown, but the driver is somehow not recognized.  Next, I add the configuration back in using the "Add New" button, then re-do the configuration process as I've described above, assigning Left and Right to the two S/PDIF logical outputs.  Once I do this, my files play just fine again.  However, this means I must go through this procedure each time I run Foobar from a freshly-rebooted system.

Any help with this would be greatly appreciated!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: andy_c on 2008-03-25 17:34:27
I just wanted to add that I just now saw that 0.9.5.1 was released.  I installed 0.9.5.1 and  the problem still occurs.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ExUser on 2008-03-25 19:02:36
Error 0404: device not found?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: volvme+ on 2008-03-26 17:51:01
My 0404 usb also lose its ASIO settings after reboot.
And... as far as I know, all 0404usb users have this problem, don't know whether the problem is in foobar2000 or e-mu, but in other applications (wavelab, cubase) the config is remembered.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: andy_c on 2008-03-27 00:32:06
My 0404 usb also lose its ASIO settings after reboot.
And... as far as I know, all 0404usb users have this problem, don't know whether the problem is in foobar2000 or e-mu, but in other applications (wavelab, cubase) the config is remembered.


Similar situation here.  WinAmp and JRiver both remember the ASIO config after re-boot.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: bubbleguuum on 2008-04-21 14:53:48
Same problem here, this is very annoying and probably a foobar ASIO bug.
There's the lost settings problem and the huge lag (a few seconds) when hitting stop, play etc.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: nightfishing on 2008-04-22 03:43:16
known issue with all 0.9x versions + Emu 0404
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Peter on 2008-04-22 10:47:06
The driver re-registers itself with a different class ID on each reboot. Apparently other apps remember ASIO drivers by name not by ID but it's a driver bug regardless IMO.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: bubbleguuum on 2008-04-22 12:55:24
The driver re-registers itself with a different class ID on each reboot. Apparently other apps remember ASIO drivers by name not by ID but it's a driver bug regardless IMO.


Is there any quick workaround you could implement or is it too much trouble ? I ask because this card is very popular with foobar users...
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: volvme+ on 2008-04-22 13:16:28
Somebody should mail e-mu and report back what they have said.
I'm too lazy for formal mails... 


edit: Anyway, I've sent an e-mail to the tech support. Waiting for an answer... 
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: andy_c on 2008-04-28 16:00:58
The driver re-registers itself with a different class ID on each reboot. Apparently other apps remember ASIO drivers by name not by ID but it's a driver bug regardless IMO.


Well, I got curious about this, so I downloaded the ASIO SDK from Steinberg to have a look at it.  One thing I noticed is that although the individual functions that make up the API are reasonably well documented, there doesn't seem to be any sort of specification that lays out what is legal and what is not when the API alone is not enough to determine this.

Their driver example in asiosmpl.cpp uses a CLSID that's fixed at compile time and never changes, but is this a requirement?

If you look at their application example hostsample.cpp, the first function called by main() is loadAsioDriver(), whose argument is the driver name, not its CLSID.  This then calls AsioDrivers::loadDriver() in asiodrivers.cpp, which in turn calls into its base class AsioDriverList::asioOpenDriver() in asiolist.cpp.  It's not until that point that the CLSID is retrieved and passed to CoCreateInstance() to create the COM object.

So on the one hand, Steinberg do not specify what is "legal" to do vis-a-vis whether or not the CLSID is allowed to change.  On the other hand, for the C++ helper class provided by Steinberg for exactly the purpose of loading the driver, the non-constant nature of the E-MU 0404 CLSID is a non-problem.  If the code provided by Steinberg for this purpose were used, it would not be a problem in Foobar2000.

It would really be nice if a future version of Foobar2000 would use the same technique for loading the driver that's specified in the Steinberg example code.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Peter on 2008-04-28 16:30:59
The whole point of CLSIDs is being able to identify registered COM servers without relying on their names and such.

Quote
It would really be nice if a future version of Foobar2000 would use the same technique for loading the driver that's specified in the Steinberg example code.
It would be even nicer if future versions of E-MU drivers stopped pretending that we have an entirely new driver registered each time the system starts.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: andy_c on 2008-04-28 18:47:08
The whole point of CLSIDs is being able to identify registered COM servers without relying on their names and such.


It seems that there is a potential problem with multiple instances though, and that ASIO doesn't implement all the COM interfaces necessary to make that happen without "extracurricular" stuff going on.  Since CoCreateInstance() isn't meant for multiple instances, this is leaving a lot of possibility for ambiguity.  Looks like E-MU is working around the multiple instance issue with the dynamically-created CLSIDs.

It doesn't sound like this is going to be resolved anytime soon.  I'll send an email to E-MU to see what they have to say about it.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Peter on 2008-04-28 20:24:24
The ASIO specification says that if you have multiple device instances handled by the same driver, they should be presented as different channel groups - which is the main reason why foobar2000's ASIO component requires you to set up "virtual ASIO devices" before using it. If other software can't deal with that, somebody needs to read the specification more carefully.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: volvme+ on 2008-04-28 21:16:44
Quote
Kristian,

Our support for audio players is limited, but I'll be more than happy to pass this information along for you! This may be considered low-priority, however.

Please remember the more information you provide, including previous correspondence in your mail, helps in troubleshooting and solving the problem you are experiencing.

Thank you,
-Tanner
E-MU Systems
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2008-06-29 14:25:50
The problem still exist. Is there any chance to solve that annoying problem?

I'd like to say that very simply player XMPlay can keep ASIO setting so why Foobar cannot
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: mchaka on 2008-08-27 21:54:34
I was thinking that maybe somebody could make a "driver" with fixed CLSID that would load (or locate) the E-MU driver by its name? I don't know how to do it but that was my two cents. Perhaps someone could explain why it's impossible or how it could be done.

Then you could choose this new "driver" instead of EMU-driver and it would work although EMU's driver's CLSID changed.

The problem still exist. Is there any chance to solve that annoying problem?

I'd like to say that very simply player XMPlay can keep ASIO setting so why Foobar cannot

Because it's not Foobar which is broken, it's the driver and other apps.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: fanerman91 on 2008-10-19 23:22:41
So, is there a quick fix for this?  Not-so-quick fix?  Any kind of fix?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Fred de Nantes on 2008-11-21 22:33:52
So, is there a quick fix for this?  Not-so-quick fix?  Any kind of fix?


I have a fix with ASIO4ALL setup like that, it works !

(http://ma.zone.free.fr//fred-de-nantes/hifi/pc/config-asio4all-e-mu0404-usb-foobar.jpg)

More informations, in french, here : http://ambiance-hifi.fr/viewtopic.php?p=77044 (http://ambiance-hifi.fr/viewtopic.php?p=77044)
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: George K on 2008-11-22 01:52:05
In my experience ASIO4All is not an adequate substitute for the native E-MU ASIO drivers.

With the native drivers, E-MU 0404 USB can switch automatically the sampling rate according to the source material. With ASIO4All, if I have E-MU set to the wrong sampling rate, Foobar crashes and looses the driver settings.

With ASIO4All it is impossible to produce any output via SP/DIF. Therefore it is impossible to verify that ASIO4All can produce bit-perfect output with E-MU 0404 USB.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kohlrabi on 2008-12-12 19:36:48
I have the same problem with a Creative Audigy 4 in Vista 64, using foobar 0.9.6 and foo_out_asio.dll version 1.2.6. Also installed the newest Creative drivers.

Additionally starting playback or switching tracks takes up to 3 seconds on some occassions.

All of this is probably bas driver support on Creative's end, but if someone knows a fix/workaround I'd be happy to know it.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: leeperry on 2009-05-02 05:36:05
sorry to bump an old thread....but is this problem still present in the latest version?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: a3aan on 2009-05-02 10:39:43
Yes.

sorry to bump an old thread....but is this problem still present in the latest version?

Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2010-01-25 14:29:06
Please explain!
The old Foobar 0.8.3 keeps ASIO settings perfectly (EMU-0404USB) so why the new version can't do it?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-01-27 12:18:48
The driver can be trivially hacked to use the same CLSID every time.
If I had this sound card, I'd do it that way.
And I've seen some other guy successfully doing that in #foobar2000 too.
Just FYI.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ExUser on 2010-01-27 13:00:37
Just use DirectSound. The DS drivers behave as you'd expect. ASIO provides no increase in audio quality.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2010-01-27 21:49:29
Just use DirectSound. The DS drivers behave as you'd expect. ASIO provides no increase in audio quality.



With the native ASIO drivers, E-MU 0404 USB can switch automatically the sampling rate according to the source material. It's impossible with DS drivers.
- ASIO - If the source material is e.g. 96kHz EMU will switch automatically to this sampling rate
- DS - If the source material is e.g. 96kHz EMU will not switch automaticaly to this sampling rate. Using DS drivers one have to switch manualy the sampling rate on the EMU Control Panel.

Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2010-01-27 21:53:27
The driver can be trivially hacked to use the same CLSID every time.
If I had this sound card, I'd do it that way...


trivially hacked... well, please tell me (us) how to do this
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ExUser on 2010-01-27 23:42:18
With the native ASIO drivers, E-MU 0404 USB can switch automatically the sampling rate according to the source material. It's impossible with DS drivers.
And it's irrelevant with a Resampler in your DSP chain.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-01-27 23:43:18
You can see the relevant part of the log here (http://yirkha.fud.cz/tmp/4b60cf33_e-mo_0404-driver-hack.html).
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: needle on 2010-05-22 09:54:21
You can see the relevant part of the log here (http://yirkha.fud.cz/tmp/4b60cf33_e-mo_0404-driver-hack.html).


Can you explain what the procedure is for replacing the JZ's with JMP's?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-09-24 22:37:13
Yirkha, so have you been successful? And if you have, can you please post how to do it ourselves, or you can give us the hacked files or something
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-09-25 05:41:34
Well I don't own E-MU 404 card, so I personally did not do anything. Nevertheless it's apparent from that IRC log that someone has indeed been successful with the modification.

I don't think you would be able to fix this yourself if the already present information didn't make much sense to you. But if you would point me to the driver package you have installed or the installed ASIO driver directly (ctasio.dll or emasio.dll or however it is called), I could probably devise a patch for you to simply apply afterwards.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-09-25 14:16:32
I have found emasio.dll in system32, so if you can do anything..... Thank you for the effort
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-09-25 14:55:08
OK, got it fine. What OS are you running, Windows Vista or 7?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-09-25 16:33:11
I' m running 7
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-09-25 16:46:35
OK, then the solution might be amazingly simple.

Backup your emasio.dll and replace it with this. The ASIO device selection should not be forgotten anymore between foobar2000 restarts.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-09-25 17:17:06
It doesn't work  every time i restart my computer it forgets
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-09-25 17:36:42
Hmm how exectly did you try it, step by step? It might need two fb2k restarts to start working properly.

Also did you see it forget the right device even when just launching fb2k, closing it and starting again? Or only when restarting the whole computer?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-09-25 17:49:42
Ok, i started the whole procedure again. I returned the original emasio, and then started foobar, set the asio drivers and the output to asio, played a song, and then restarted it for a few times and then closed it, replaced the original emasio with your's and started foobar again, and restarted it for a few times, and i restarted the computer, and it forgets  And i never had the problem when restarting foobar, it only forgets when the computer is restarted
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-09-30 01:12:41
All right. Sorry for the previous confusion and this delay in my reply - I needed to get some more time to look at this all.

Apparently the emasio.dll itself works fine, it caches the relevant information in registry, etc.

But there is another player in the game, a process called emaudsrv.exe which runs as a service. It's quite useful, as it for example automatically registers the ASIO drivers for each device you plug in and so on. But, unfortunately it also erases all registrations when the computer is shutting down - and that's the real problem here.

A simple solution would be to just hack emasio.dll to always return the same ID for all registrations, which is what I have originally suggested (and what has been already done on another forum recently). But that would fail if somebody used more than one E-MU device on the same computer and I like to do things properly.

So I modified the emasio.dll to still generate a "random" ID, but based on the device name reported by the OS (MD5 sum of the NT device path string). That should give an unique ID for each device, but still keep it constant for the same one.

Again, I don't have any E-MU hardware to test, but I've verified the relevant functionality of the DLL as well as I could and everything seemed working as expected.

The fixed DLL for download:
emasio.dll x86 (http://yirkha.fud.cz/tmp/4ca3d396/emasio.dll) (patch for original DLL with size 58880 Bytes, md5sum 79df09ce7d2b51ec0e0f3456d460d1d7, in "C:\Windows\System32" on Win/x86 [32-bit] and "C:\Windows\SysWOW64" on Win/x64 [64-bit])
emasio.dll x64 (http://yirkha.fud.cz/tmp/4cbefb3f/emasio.dll) (patch for original DLL with size 65024 Bytes, md5sum a0f7c05a90100a5a701943ec0b997211, in "C:\Windows\System32", on Win/x64 [64-bit] only)

2010-10-18: Added the x64 version.
2010-10-20: Fixed the x64 version.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: ZenZendra on 2010-10-02 17:28:36
I'm sorry for the delayed answer, but it was worth it, because the first time i try it, it didn't worked, and i didn't have the time to inform you about it. And then, suddenly yesterday it worked!! It needed a few restarts obviously, and i can't believe it yet, i'm so encredibly grateful four your help Yirkha, i don't have enough words to say thanks, so .... THANK YOU a million times. Now i can really enjoy my music with foobar without this annoyances. And this bug is present for years now, and yirkha solved it in one day practically!!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-03 17:51:34
That's great news! You are welcome, I'm glad I could help you to solve this.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: intruder.outsider on 2010-10-14 19:46:10
That's great news! You are welcome, I'm glad I could help you to solve this.


Hi Yirkha

I 've found your patched version of emasio.dll.
It works great !
Many thanks
 

Armando
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-14 22:05:42
I'm on Windows 7 x64, and I guess my card uses a 64-bit version of emasio.dll (it severely differs with 32-bit bit one). I'd really appreciate it if someone could make the corresponding changes to this 64-bit version. I had tried to do them myself, but have found myself completely lost in comparison and disassembly due to very little experience with low-level code and executable file structure 
I've made emasio.dll x64 available for download: http://sharebee.com/f02838f5 (http://sharebee.com/f02838f5)
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-17 23:28:20
Bah, I've thought it will be neccessary to handle the x64 version too ever since I found out about the emaudsrv service process, but secretly hoped we could do without it...
I'll look at the 64-bit version again when I have time and keep you updated here.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-18 02:35:11
OK, I've modified the x64 version too - see the updated [a href='index.php?act=findpost&pid=724792']post #41[/a] above.
Again, I can't be sure I did everything right, but the relevant function has been working correctly here as far as I can tell. Try it and see...
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2010-10-18 09:12:22
Hello, Yirkha
I am running Win 7 64bit, E-mu 0202 and foobar v1.1
I have tried emasio.dll x64 you made but it didn't work for me.

Please correct me if I am doing something wrong, but that is my process:

I place emasio.dll x64 ver. to Windows\System32 overwriting an old one. Restart computer. As a result - "No ASIO drivers found" in foobar and I also unable to change sample rate in E-MU control panel.

I also tried placing emasio.dll x86 ver. in both dirs simultaniously: Windows\System32 and Windows\SysWOW64. The result is: ASIO works perfectly as on native dll but is still "forgetable" in foobar.

Any solutions please?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-18 12:10:26
I am running Win 7 64bit, E-mu 0202 and foobar v1.1
I have tried emasio.dll x64 you made but it didn't work for me.
OK, let's do some information gathering first.
Could you find your original emasio.dll in both C:\Windows\System32 and C:\Windows\SysWOW64 and tell me the file size of both of them?

I place emasio.dll x64 ver. to Windows\System32 overwriting an old one. Restart computer. As a result - "No ASIO drivers found" in foobar and I also unable to change sample rate in E-MU control panel.
Hmm how did you replace the old .dll? Because that sounds like both fb2k and the E-MU software could not use the DLL at all.

By the way, it must be done from a 64-bit process (e.g. Explorer started simply from the Desktop or Start menu), because 32-bit processes see Windows\System32 as an alias for Windows\SysWOW64 only. But that would be apparent in the file size test above (they would or would not differ).

I also tried placing emasio.dll x86 ver. in both dirs simultaniously: Windows\System32 and Windows\SysWOW64. The result is: ASIO works perfectly as on native dll but is still "forgetable" in foobar.
Ideally, on 64-bit Windows, the x86 DLL should go to SysWOW64, the x64 one to System32. If this worked as you described, it sounds again like you see the virtual System32 only. But maybe I'm wrong on that account, we'll know more based on my first question above here as well.

One more note regarding the number of restarts needed -
Originally, upon Windows startup, the driver finds a seemingly new USB device attached and generates a new random ID for it. When you run fb2k, it doesn't recognize anything under the old ID and needs a manual change.
With the patched version, the driver generates always the same pseudo-random ID as long as the device is the same too. But for that to show any effect, you need to restart two times (first restart: it generates the new kind of ID and you have to set it in fb2k, second restart: it generates the same ID again and fb2k finally remembers the settings).
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2010-10-18 13:07:23
Thank you for reply.

Ok. For the clarity of the experiment I have reinstalled my native E-MU drivers again. Now I find emasio.dll in C:\Windows\System32 it is 65 024 bytes and in C:\Windows\SysWOW64 it is 58 880 bytes.

They ARE different indeed. So I must be running 64bit process now? So I am going to do this once again as you mentioned: "on 64-bit Windows, the x86 DLL should go to SysWOW64, the x64 one to System32" (system asks for overwrite, I say yes). and restart 2 times... and see what it brings...
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2010-10-18 14:10:23
Yirkha, thank you it works finally!!!

It seems like I have messed up something first time...
I want to clarify for once again for Win7 64bit users:

1. put x86 emasio.dll to SysWOW64
2. put x64 emasio.dll to System32
3. reboot
4. set up ASIO output in foobar manually
5. reboot again


foobar should "remember" and be able to play through ASIO as it starts.

Huge thanks again, Yirkha! You are genious!!! I have been stuck with this problem for whole 3 years and no one on the internet had any working solution!!! I am *****ng happy now, becouse I dont have to push the same buttons again and again. Got plenty of time for better tasks freed! ,)))
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-18 14:14:52
Awesome!
I was already thinking what I had possibly screwed up and how to debug it, now I'm happy I don't have to anymore
Enjoy your music, I'm glad to help.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2010-10-18 14:21:19
You are great! It would be nice to hear a feedback from other users... )
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-18 21:40:44
Yirkha, thank you for all the trouble! Guess the driver dev team at Creative Professional could learn a thing or two from you  Especially about how to respond fast to the issues users are experiencing.
Now to the subject. It turns out I was wrong about the absolute need of an x64 ASIO driver under x64 Windows. The thing is - all the 32-bit sound software I have (sequencers, editors, etc.) uses the 32-bit emasio.dll. That includes FB2K and E-MU's own control applet, too. Figuring this out was easy: I'd deleted emasio.dll using 32-bit file manager and have tried to use some software - there's been no ASIO device for me.
Nevertheless... thanks to Yirkha's effort we're now ready for the future (i.e. 64-bit version of foobar2000)! And that's truly reassuring.

Also, I want to comment on a problem-solving algorithm that T_B_Good has suggested. I think there's no absolute need in rebooting on steps 3 and 5 if you use an external audio interface (like 0404 USB). You can just turn the interface's power off and back on, instead.

And one last thing: when you are replacing the files, make sure that you use a 64-bit file manager (like Windows Explorer), or else you may end up double-replacing the same 32-bit file, because for a 32-bit file manager System32 and SysWOW64 folders are equal
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2010-10-19 11:34:33
Kiyos, I suspect that turning on/off is not equal to rebooting. At least in my case with E-MU 0202. Becouse my foobar used to forget ASIO settings only due to system reboot and not after simple on/off operation.

Its interesting. So you state that Yirkha's x86 dll would be enough to solve foobar-ASIO problem on both Win7 32 and 64bit?

Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-19 13:48:52
You are right that all 32-bit applications use only the 32-bit emasio.dll as their ASIO driver. But this DLL for example reads some information from HKEY_LOCAL_MACHINE registry hive (like HKEY_LOCAL_MACHINE\SOFTWARE\ASIO\<name>), which a standard user application cannot write. So they have to be written by some elevated process earlier - and that's what the E-MU service does, through emasio.dll too. Because the service will be (I believe) 64-bit on x64 Windows (or maybe both 32 and 64-bit, I don't really know), I think the x64 version of the driver is needed too, even if you use 32-bit applications only.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-19 22:17:31
Here's some further feedback.
After replacing both DLLs I keep getting Microsoft Register Server (regsvr32) error in a "the program was terminated unexpectedly" form when I start foobar2000 for the first time after booting into Windows (or resuming from hibernated state). This one time FB doesn't start, but the next time I click on its shortcut it fires up all good and I can listen to music thru 0404's ASIO straight away, without re-configuring.
I've saved a copy of Windows' error report on this issue and I can share it anytime, should you need it.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-19 23:43:51
Please do share, sounds like I screwed something up...
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: a3aan on 2010-10-20 09:25:16
Nice stuff. EMU just released new (beta) drivers. Haven't tried them yet.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-20 15:26:54
After replacing both DLLs I keep getting Microsoft Register Server (regsvr32) error in a "the program was terminated unexpectedly" form when I start foobar2000 for the first time after booting into Windows (or resuming from hibernated state).
OK, with the log you provided I found the cause of the crash. Please try the updated x64 version from [a href='index.php?act=findpost&pid=724792']here[/a].

EMU just released new (beta) drivers.
*fingers crossed*
Hacks sucks.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: faau on 2010-10-21 04:47:53
new beta driver for win7 haven't solve this problem....
         

emu reply:

Dear XX

Thank you for contacting us at  E-MU Customer Support.

Well, we would expect that the new beta-driver will work fine as similar to other commercial media players, like WMP, ITunes or Winamp, still there is no guarantee that other software such as Foobar will encounter minor problem.

As you can understand, we are unable to cover support to all available softwares around but we will try to look into it .
However, we would also suggest that you inquire directly from Foobar Developer and clarify the problem. if there is
any additional solution to it.

Should you require further assistance please do not hesitate to contact us.

Please retain all the previous correspondence when replying to this email.
Best Regards,
Arman
E-MU Technical Support

We would like to announce that E-MU is now featured on YouTube :  http://www.youtube.com/user/EMUsupport (http://www.youtube.com/user/EMUsupport)  and FaceBook: http://www.facebook.com/EMUSystems (http://www.facebook.com/EMUSystems)
You're invited to share your positive views and other feedbacks on the following websites which may contribute and improve our E-MU products in the future ahead. Check us out there and get some interaction among the E-MU users.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-21 14:59:18
Well, I assume they have already stated somewhere they have their reasons for registering the ASIO drivers anew each time a device is detected. But you might forward them my solution to "generate a pseudo-random GUID based on the MD5 sum of NT device path instead of pure random ID for compatibility with applications remembering ASIO devices not by name but driver GUID", that seems like a good compromise to me.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-21 15:11:29
At least there's hope for steady Windows 7 support, whatever it means...
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-21 22:57:26
Sorry, the previous post was irrelevant
I've tried the newest x64 version of the .dll, and - no issues so far. Not even that regsvr32 one. Haven't tried it on every piece of software I have, though - only on FB2K and on a standalone VST plugin, but I will keep you informed on my findings. Thanks.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-10-22 11:07:53
No problem, of course you are free to comment on anything else. I'm glad for your continuing feedback, you don't see that as often as one would like.

Good to hear it works fine now. The last fix did not change the behavior in any way - the problem was just that the emaudsrv.exe process is being hotpatched by Windows for some reason and it redirected some API functions, which I did not expect.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Kiyos on 2010-10-23 22:59:51
Further tests have proved that the new libs work as intended. At least, with a single E-MU device present in the system. Is there someone here who has two or more?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Axel555 on 2010-10-26 17:50:45
Yirkha: Thanks a lot for your patched EMU ASIO driver!
Using it with my Emu 0404 and Foobar 1.0.3 and everything working fine. Awesome. I tried to find a fix an year ago and failed.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yeahyeah2002 on 2010-10-30 04:43:26
I just brought 0404usb about 2 month and annoying by this problem.
Luckily I found this post.
It fix now, just leave this message and many thanks to Yirkha.
I'll tell all my friends who using 0404usb+foobar2k about this great news!!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Petru on 2010-11-11 23:58:31
Thank you Yirkha!!! You made this world a better place! 
just for stats: Win7 x64, 0404 usb, 8.04 firmware, 6.00.01.0001 Beta
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2010-11-16 00:11:54
Does it work on Windows XP?
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Yirkha on 2010-11-16 13:06:03
Yes, sure.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yayacek on 2010-11-16 15:03:04
Yes, sure.


Thx, you're Great!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: rkay5 on 2011-01-18 00:38:33
Hi,
  I'm using e-mu 0404 usb os w7 64bit. To get a round the aiso problems in foobar I use the Kernel Streaming support it allows bit-exact playback bypassing Windows kernel mixer and does not slow down my computer like aiso does.For recording I do use aiso in calkewalk Sonar LE 8.5 without any problems.And it all sounds great.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: yip2133 on 2011-02-05 16:40:16
To Yirkha

Many thanks to you. My foobar now works perfectly.

Peter Yip from Hong Kong
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: sauron_pk on 2011-03-06 03:49:15
Yirkha you are great men!!

Can you please do me a favor and for anyone who is using this card with the latest beta drivers?
in these new drivers the dll was changed for another one, anything was updated(i don't know what) but the file creation and size it's different from the latest stable drivers...and the product version too(from the properties)

so here are the files, can you please fix it in these?


http://www.gigasize.com/get.php?d=c24g668tl8b (http://www.gigasize.com/get.php?d=c24g668tl8b)  x86 system32


http://www.gigasize.com/get.php?d=k3fkcym4dcd (http://www.gigasize.com/get.php?d=k3fkcym4dcd) x64 SystemWOW64


thanks a lot!!!!!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: (((STEREO))) on 2011-03-23 15:34:04
Yirkha - Can't thank you enough for addressing this frustrating problem...THANKYOU.

I purchased the 0404 a few weeks ago KNOWING your Foobar fix was available.

QUESTION for 0404 users:
Will this driver switch BITRATE automatically or do I still need to switch between 16 and 24 bit manually (as I assume from what I see in the Foobar ASIO config panel)?

Cheers,
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: Marco89 on 2011-03-29 18:58:08
Is there the similar patch for E-MU 0204? Because I have the same problem with ASIO drivers installed on Win7 64x and this patch is not working with my card.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: sauron_pk on 2011-04-05 14:54:55
Yirkha you are great men!!

Can you please do me a favor and for anyone who is using this card with the latest beta drivers?
in these new drivers the dll was changed for another one, anything was updated(i don't know what) but the file creation and size it's different from the latest stable drivers...and the product version too(from the properties)

so here are the files, can you please fix it in these?


http://www.gigasize.com/get.php?d=c24g668tl8b (http://www.gigasize.com/get.php?d=c24g668tl8b)  x86 system32


http://www.gigasize.com/get.php?d=k3fkcym4dcd (http://www.gigasize.com/get.php?d=k3fkcym4dcd) x64 SystemWOW64


thanks a lot!!!!!

anyone :$
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: sauron_pk on 2011-04-27 00:42:15
up                   
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: FreeBorN on 2011-06-18 20:36:41
The owner of an EMU-0404 is thanking Yirkha for his solution (emasio.dll) which works perfectly and remembers ASIO settings on 2'nd restart.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: hmoewou on 2011-06-26 16:03:36
Thank you very very much Yirkha!

I'm using W7, 64 bit and an Emu 0404 USB with the stock drivers for XP/Vista. No need for the W7 beta driver, these old drivers work just fine under W7 as well.

I did the procedure as described by T_B_Good here in post #51 and i'm using the files uploaded by Yirkha in post #41.

Works like a charm, including auto sample rate switching.

Thanks again!
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: T_B_Good on 2011-10-29 15:21:31
Marco89, this solution works for E-MU 0204 as well. I have upgraded from 0202 to 0204 and firstly installed its native driver provided. than i replaced DLLs and it is working again.  just make sure you put x86 to SysWOW64 and x64 to /System32 not the opposite!

So to conclude:
As confirmed, Yirkha's DLLs should work for the models: 0202, 0204, 0404. may also work for other E-MUs.
Title: E-MU 0404 USB - foobar2000 "forgets" ASIO config on shutdown
Post by: AudioOmen on 2011-11-28 10:16:36
Any news about the problem guys?

I've recently bought E-MU 0204 and faced exact problems on Windows 7 64x with click noises. I've investigated the problem and it certainly happens due to damn driver that makes click sounds when signal goes to the soundcard, e.g. when music or system sounds are started or stopped. I've even wrote a small program that captures sound device with void .wav file and plays it infinitely - problem disappears. However, it seems to be like a wooden wheel attached to the Mercedes. WTF?!

Also waiting E-MU's horrible support answer about drivers renewal.