mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
Add files via upload
This commit is contained in:
parent
821be594f2
commit
3ffac2e90e
24
tools/list_audio_devices.py
Normal file
24
tools/list_audio_devices.py
Normal 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()
|
Loading…
Reference in a new issue