E
Size: a a a
СИ
СИ
СИ
k
k
k
СИ
def listen():
while True:
data = stream.read(4000, exception_on_overflow=False)
if (rec.AcceptWaveform(data)) and (len(data) > 0):
answer = json.loads(rec.Result())
if answer["text"]:
print('ок')
yield answer["text"]
for text in listen():
if text == 'сделать скриншот' or text == "сделай скриншот" :
try:
os.startfile(r'C:\Windows\System32\SnippingTool.exe')
except:
pygame.mixer.init()
s = pygame.mixer.Sound(PATH_TO_WAVnotfiles + random.choice(notfiles))
s.play()
print('файл не найден')СИ
k
СИ
СИ
k
СИ
СИ
СИ