It's great that people from all over the world are building InMoov. But it is always speaking english (which is good for me because I speak english), here's a way to have it speak what ever language you want.

I have a few scripts where it introduces it's self in different languages, for example;

def speakfrench():
    i01.mouth.setLanguage("fr")
    i01.mouth.speak("bonjour je suis la InMoov robot")
    i01.mouth.setLanguage("en")
 
Set the language to what you want it to be, in this case French - use Google's language identifier ("fr");
Type in what you want it say, in that language. I use Google Translate to get the spelling.
Then set it back to English ("en")
 
Have fun!

GroG

10 years 2 months ago

I really like when you post information you've discovered bhouston !

Just so you know you only have to do this :

def speakfrench():
    i01.mouth.setLanguage("fr")
def speakitalian():
    i01.mouth.setLanguage("it")
def speakenglish():
    i01.mouth.setLanguage("en")
 
def sayhello():
  i01.mouth.speakBlocking("hello")
 
When you tell it to speak French - it will speak french for ALL the utterances, until you tell it to speak English again.  So, hello will become bonjour.. Or if your starting with French i01.mouth.speakBlocking("bonjour")  will be hello if speakenglish is called before.  Hopefully, I have not made this more confusing..

Markus

10 years 2 months ago

I tried to get the speech swedish to work a while ago bet the letters å ä ö is making problems.

have you got any ideas how to fix it bhouston

bhouston

10 years 2 months ago

Can you change the language of your computer ?

I have this script;

      i01.mouth.setLanguage("sv")
      i01.mouth.speak("hej ja ear roboten inmoov")
      i01.mouth.setLanguage("en")
 
I got it from you and it sounds good to me, although i don't speak Swedish.
I have been using Google translate on my iphone for the translations, I'm hope it is correct.

 

Markus

10 years 2 months ago

the problem is that it should be spelled är not ear.
In swedish we have the extra letters å, ä and ö

bhouston

10 years 2 months ago

Does anyone know an easy way to change the voice from male to female and back again in a script?

Hmm.. no .. its not possible at the moment, BUT its a good idea...
If the URLS had names associated with them .. then we could do something like

speech.setURL("male","http://jhacket....")
speech.setURL("female","http://google....")
speech.setURL("somethingElse","http://google....")

Then further in the script you could :

speech.set("male")  # and all subsequent utterances are male
speech.speakBlocking("I'm a dood")

speech.set("female")  # and all subsequent utterances are female
speech.speakBlocking("now I'm a lady")

GroG

10 years 2 months ago

In reply to by bhouston

Heh,

I was proposing to have "named" URLs - so that in the code they soundfiles (male/female/en_gb/... etc) could be switched dynamically in a script..

It has not been implemented yet.. someone still has to actually make it work ;)

GroG

10 years 2 months ago

Heh, now I'm starting to understand you .. 

Markus you want to spell Swedish words and have it speak Swedish, ignorant as I am I assumed you wanted to spell English but say Swedish...

Ok,  If we are using google as a service for Speech (which everyone is at the moment) - then the words are only as good as what Google speaks them.

There is ALSO a problem in that the Python text editor probably only supports ASCII characters (which is English - not many special characters) - this could be changed, but its not worth it if Google can't say the Swedish word correctly.

Markus - have you tried Google's (speaker) speech or translate for Swedish?  I thought it was getting the characters correctly, but the pronuciation is bad.  Is that correct ?

Markus

10 years 2 months ago

i try to be creative but it dont sound good.

google translate has no problem with Swedish

i think python sends it wrong to google because it don't understand å ä ö

OK ! .. then there is hope if google translates makes decent Swedish. Is problem#1 then, the place where you edit & run the script do not accept the correct characters?

Or does it, and you feel they are not being relayed to google?