Board index FlightGear Support Tools ATC-pie

No voice

ATC-pie is a radar air traffic control simulation program for the FlightGear multi-player network.

No voice

Postby Emile » Wed Nov 08, 2017 4:11 pm

Hi,

After being introduced to ATC-pie at the Flightsimweekend I gave it a try.
Unfortunately, I don't hear the pilot voices. This is version 1.4.1 on Windows 7, Python 3.5.1.

To get the pyttsx modules to start correctly I installed pyttsx3 and changed the import in ext/tts.py to read
Code: Select all
import pyttsx3 as pyttsx


This was based on a hint at https://stackoverflow.com/questions/296 ... med-engine

This caused the startup error to dissappear. Now I see in the startup window that the Speech synthesis module loaded successfully. In a Python interpreter the script
Code: Select all
import pyttsx3
engine = pyttsx3.engine()
engine.init()
engine.say("Hello")
engine.runAndWait()


works fine, so I think every installed correctly.
I did check the option "Voice synthesis" in the solo game options menu but still no voices in solo game.

What can I do?

Thanks,

-Emile.
Emile
 
Posts: 2
Joined: Wed Nov 08, 2017 3:53 pm

Re: No voice

Postby mickybadia » Wed Nov 08, 2017 9:04 pm

First, thanks for the incidental pointer you gave to pyttsx3. My README pointed to a specific version of pyttsx for Python3, but you went about this in a different way. People should not be editing the source code in their download, so I will include pyttsx3 directly in the next version, because it is more easily pip-able.

Of course, thank you also for trying this out. And welcome aboard.

For the rest, your report is strange because:
Code: Select all
import pyttsx3
engine = pyttsx3.engine()
engine.init()
engine.say("Hello")
engine.runAndWait()


This did not run on my system: "AttributeError: 'Engine' object has no attribute 'init'"
For it to work, I have to merge lines 2 & 3 into one single: "engine = pyttsx3.init()"
What does that do on your side?
mickybadia
 
Posts: 368
Joined: Tue Sep 24, 2013 9:12 am

Re: No voice

Postby Emile » Sat Nov 11, 2017 4:43 pm

Sorry, copied the wrong part into the mail. Indeed, your code is what I tried succesfully. This gives me voices.

-Emile.
Emile
 
Posts: 2
Joined: Wed Nov 08, 2017 3:53 pm

Re: No voice

Postby jmwilton » Thu Feb 01, 2018 1:20 am

For what it is worth...I have been having a "No Voice" problem on my installation on Windows 10.
I have finally been able to make it work by modifying the code slightly. I am sure there might be a configuration change that I can also make to achieve the same result.

In the SpeechSynthesiser __init__ method I added the line to the end:

en_voices.extend(vid for vid, langs in vdct.items())

following:

en_voices.extend(vid for vid, langs in vdct.items() if any('en' in lang for lang in langs))

It appears that all the vdct.items returned only had "EN" not "en" in the results.
I didn't want to break anything else on my system so I did not try changing things in the registry.

Don't know if this helps anyone else...but it worked for me.
jmwilton
 
Posts: 3
Joined: Thu Feb 01, 2018 1:12 am

Re: No voice

Postby mickybadia » Wed Feb 07, 2018 7:45 pm

This looks non standard... do you know what driver is in use?

I would be interested to know if many users have the same issue. Who gets capital language codes when running the following code in a Python3 console?
Code: Select all
import pyttsx3
engine = pyttsx3.init()
for v in engine.getProperty('voices'):
  for lang in v.languages:
    print(lang.decode('utf8'))
mickybadia
 
Posts: 368
Joined: Tue Sep 24, 2013 9:12 am

Re: No voice

Postby wkitty42 » Thu Feb 08, 2018 6:02 am

i tried the code, just because... but i don't have that pyttsx3 module and don't know/remember how to install them :/
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 4163
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5

Re: No voice

Postby mickybadia » Thu Feb 08, 2018 8:24 am

To install, use pip3.
NB: For Linux at least, the README should be helpful.

Have you had the no voice problem too?
To clarify, this test only applies to those without voice despite a "Speech synthesis module loaded successfully." message at start.
mickybadia
 
Posts: 368
Joined: Tue Sep 24, 2013 9:12 am

Re: No voice

Postby wkitty42 » Thu Feb 08, 2018 12:58 pm

i haven't tried messing with voice stuff... i only wanted to see what the lang results were...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 4163
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5


Return to ATC-pie

Who is online

Users browsing this forum: No registered users and 1 guest