printing command

This commit is contained in:
talksik
2023-04-27 16:47:46 -07:00
parent 86f16a6103
commit 7f79208ef5
+5 -2
View File
@@ -4,14 +4,17 @@ import os
def robot(text):
os.system('espeak --stdin "' + text + '" | aplay -D plughw:2,0 ')
command = 'espeak --stdin "' + text + '" | aplay -D plughw:2,0 '
os.system(command)
return command
if __name__ == '__main__':
while True:
try:
robot("Hello world how are you doing today?")
command = robot("Hello world how are you doing today?")
print(command)
time.sleep(5)
except KeyboardInterrupt:
break