Initialize AudioDeviceManager always return "No such device"

I wrote the following code:

AudioDeviceManager adm;
adm.setCurrentAudioDeviceType("ASIO", true);
cout << adm.initialise(2, 2, nullptr, true, "Yamaha*") << endl;

But it always outputs :“No such device: Yamaha Steinberg USB ASIO”

I’m pretty sure I have set up my sound card correctly, for it can work very well in other applications.
But why it can’t even initialize successfully?
I got pretty frustrated at this problem :sob:

Hello ! Did you enable ASIO in the ProJucer ? Do you have the ASIO SDK Installed too ?

Yes. I’ve done that.

And I tried:

adm.initialise(2, 2, nullptr, true);

to try to initialise with the default device.
It does return an empty string, but when I try:


I fount that this was a zero pointer……
I have no idea what had happened……
I think these two problems maybe have some connection, but I can’t figure out why……
Can you help me? thx~

All right…
I added one line of code:


and everything’s fine…

1 Like

Hi Jerry, where did you add that?
I’m curious because we’ve had so many issues with ASIO drivers, and also the Yamaha/Steinberg one.

At the beginning of the main() method.
I think this issue maybe have something to do with the COM in windows

Browsing the juce ASIO code i dont see a CoInitialize() call. It should be there for every thread using COM. Just to sanity check, its in PortAudio ASIO and in juce WASAPI apis as well. So, looks like a juce bug to me.

OK. I’ve fixed this on develop.

Thnx, Fabian.
We’ll try ditching portaudio again.