Add files via upload

This commit is contained in:
DJ2LS 2021-03-04 15:13:12 +01:00 committed by GitHub
parent 821be594f2
commit 3ffac2e90e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,24 @@
#!/usr/bin/python3
# -*- coding: utf-8 -*-
import pyaudio
def list_audio_devices():
p = pyaudio.PyAudio()
devices = []
print("--------------------------------------------------------------------")
for x in range(0, p.get_device_count()):
devices.append(f"{x} - {p.get_device_info_by_index(x)['name']}")
for line in devices:
print(line)
list_audio_devices()