-
Notifications
You must be signed in to change notification settings - Fork 151
how to get channel name of audio device with ASIO driver? #348
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
This is currently not implemented. See #4 (comment) and #85 for a possible implementation. |
@mgeier hi, i have try to rebuild the .dll lib, including the following method:
then i replace the intial libportaudio64bit.dll locates at C:\Program Files\Python\Python38\Lib\site-packages_sounddevice_data\portaudio-binaries then i add a method to the sounddevice.py, reference to rholl: def asio_get_input_channel_name(device, channel):
"""Retrieve the name of the specified output channel.
Parameters
----------
device : int
Device ID. (aka The global index of the PortAudio device.)
channel : int
Channel number from 0 to max_*_channels-1.
Returns
-------
The channel's name : str
"""
channel_name = _ffi.new('char*[1]')
_check(_lib.PaAsio_GetInputChannelName(device, channel, channel_name))
return _ffi.string(channel_name[0]).decode() finally I write a demo code: import sounddevice as sd
# from sounddevice_GitHub import sounddevice as sd
print(sd.query_devices())
print(sd.asio_get_input_channel_name(68, 0))
print(sd.asio_get_input_channel_name(68, 1))
print(sd.asio_get_input_channel_name(69, 0))
print(sd.asio_get_input_channel_name(69, 1)) sd.query_devices() is ok, but sd.asio_get_input_channel_name() is wrong, the error feedback is :
so how to make the method 'PaAsio_GetInputChannelName' callable in python? thanks. |
You'll have to copy the missing function definitions from the PortAudio header files to sounddevice_build.py. |
Any luck with your script @bactone? I'm also highly interested in being able to list ASIO channel names using PySounddevice. |
hi, could anyone tell me how to get channel name of audio device with ASIO driver? or is it possible to do it with sounddevice?
for example, if we use:
to get device list, we can obtain all available devices , including those with ASIO driver:
69 Cube 6Nano, ASIO (20 in, 20 out)
we can see the above device contains 20 input channels and 20 output channels, we can use these channels with the corresponding channels index from 1 to 20, for example:
but one step further, how to get the corresponding channel names? in soundcheck, the channels of device with ASIO driver can be obtained as:

besides those channel names are also listed in the Built-in software of soundcard ICON nano6:

so how to get the channel names of audio devices ? pls help, thanks
The text was updated successfully, but these errors were encountered: