mycroft-precise
mycroft-precise copied to clipboard
Index Device on Open PyAudi
On Record and collect, precise please in args of open PyAdio input_device_index = XX,
Because for example, my respeaker has need precise device -D ac108 in record by example :)
you can run the following python code to see your exact device index
import pyaudio
p = pyaudio.PyAudio()
info = p.get_host_api_info_by_index(0)
numdevices = info.get('deviceCount')
for i in range(0, numdevices):
if (p.get_device_info_by_host_api_device_index(0, i).get('maxInputChannels')) > 0:
print("Input Device id ", i, " - ",
p.get_device_info_by_host_api_device_index(0, i).get('name'))