Asked — Edited
Resolved Resolved by DJ Sures!

Talk Servo. The Mouth Remains Open After Speaking

I added a mouth to my robot. I'm trying to let it move while speaking. I tried with "talk servo" and speak synthesis. It works, but I found 2 problems:

  1. at the end of the sentence the mouth always remains open. servo positions are : min =110 (mouth closed), max=140 (mouth open). I tried checking "invert" in the talk servo configuration window, but this way it doesn't move at all. How should "invert" be used ? Can I in some way force the mouth closed at the end of the sentence,?
  2. For long sentences the mouth stops moving well before the sentence ends. The sync between speech and servo movement is not good. Could it be made better ? Sound servo with Soundboard v4 might give better results ?


ARC Pro

Upgrade to ARC Pro

Your robot can be more than a simple automated machine with the power of ARC Pro!

#1  

ERRATA CORRIGE: 110= mouth open,140=mouth closed

#2  

Hi, community. Nobody replied. In the meantime I found myself the solution to problem 1). I don't need anymore help for this problem. The solution is: For getting the mouth closed at the end of the sentence, I had to check the "invert" box in talk servo window. I discovered that this option only works if min is <90 and max is >90. So I had to fit the servo bracket accordingly.
I still need help for sync between speech and mouth movements (problem 2). With short sentences (1-2 words) it's OK, but for longer sentences (10 words) the mouth keeps moving for seconds even if the speech has ended, or viceversa, the mouth stops moving before the speech ends. It's different for different sentences, In an apparently unpredictable way. Any solution ?

PRO
Synthiam
#3  

you got it! Minimum is always less than maximum as per the definition of the words. For more information, see this tutorial: https://synthiam.com/Tutorials/Lesson/49

Also, you may have to be patient and give the community more than a few hours to answer a question.

User-inserted image

#4  

OK, DJ. All OK about open/close mouth , invert etc. I'll be more patient. Usually community members reply very quickly. This time I was quicker than them !

What about the problem 2) ? Why is there a large and unpredictable (for me) difference between duration of speech and duration of servo movement ? For some sentences servo stops much before speech ends, for others it goes on moving a long time after speech has ended. How to control this phenomenon ?

#5  

@lornardo46, which add project are you using for your speech to move the mouth? Can you post a sample project to help understand you issue?

Thx

#6  

I'm posting my project.
The problem is in speech synthesis and talk servo, that moves the robot mouth, following the speech. There are three sentences. For the first sentence , the mouth is rather synchronised with the speech. For the other, shorter , sentences the mouth keeps moving even if the speech has ended. This probably may be adjiusted setting the delays in the talk servo configuration window, but this setting is unique for all sentences. How to achieve a good sync for all sentences ?roby.EZB

#7  

@Lorn, I will look at this tonight, currently working long and weird hours. Thanks for your patience.

#8  

@Lorn, what type of robot is this? I have an Inmoov and do not use the inverted on the servo in the Talk Servo. Here is a picture of my settings.

I used the 3 robot laws from iRobot to set my mouth movement. I had to play with each settings to get it to stop every time my robot said the 3 laws, after that most any small or large words seems to work. It might be because you servo is inverted or, not sure?

here is my 3 laws... put this in a script to run.


SayWait(&quot;The Three Laws where programmed into robots to protect humans from harm by robots.  A robot may not injure a human being or, through inaction, allow a human being to come to harm. A robot must obey orders given to it by human beings, except where such orders would conflict with the First Law.&quot;)

You have to play with each of the setting in the red circled settings to get it right. Remember there is a Question "?" on each of the settings in the Talk servo config to tell you what each one does.

User-inserted image

Can you put the speech that you have on many Speech Synthesis in you Speech Recognition, that way you can use the "SayWait command? Using the SayWait command allows the speech to finish before starting a different command thread.

It would help to see a picture of the mouth to get a better idea as to how it's driven.

Hope this helps, maybe other we also make suggestion too.

Cheers,

#9  

My robot is a self-made walker , using ezb and hitec maxi servos . It's 75 cm tall. For his mouth it uses a micro servo moving the lower lip. I had to use the invert option in the configuration of the talk servo, depending on how the servo was mounted and its sense of rotation. Otherwise the mouth would have been always open except while speaking. This should have no effect on servo movement timing. I put in the project the three laws and your settings. The speech lasts 25 seconds, but the mouth stops moving after only 20 seconds, while the speech is going on for 5 seconds. Timing depends on those setting . With the three laws and my own settings, the mouth kept moving for 10 seconds after the speech had finished !...

The problem I'm trying to solve is : A sentence needs an accurate setting to be realistic, but those settings may not be good for different sentences. A compromise is required.

#10  

@Lorn, ok I understand, keep playing with those setting and you should get it working correctly. Or at least very close to it working properly I had to fool around with my own quite a few times before I got it to where it's looks somewhat or realistically speaking.

Good luck and let us know if you get it working.

#11  

@Lorn, before you checkd the invert servo in the talk servo configure menu and the mouth stayed open after saying a sentence, did it seem to work ok then? If it did I have been reading and watching some videos on YouTube.

You can reveres the direction of your servo by opening the servo and reverse the motor wires and Reverse the the 2 out side wires on the pot. Just another thought. https://m.youtube.com/watch?v=T_BvPGEn-to

#12  

Un checking the invert box swaps open and closed mouth, but timing remains the same. No need to modify the servo.

#13  

@Lorn, hey I just tested your project, try slowing you servo down. In this video am using my init script and my talk servo setting.

My mouth shuts before the end but I know with a little more tweaking I probably could get it right on. https://youtu.be/eO3egGgr1kk

Example to set your servo min & max then your servo speed


Setservomin (0.d1, 120)
Setservomax (0.d1, 160)
Servospeed (0.d1, 1)

Give it a try

#16  

Ok, merne. Those settings have no effect on sync mouth/speech. The only way to get good sync seems to be adjusting the settings in the talk servo configuration page. But a configuration good for a long sentence is not good for a short one and viceversa. I think I'll have to avoid long sentences, and use only sentences of the same length.

PRO
Synthiam
#17  

Split your sentences into smaller ones using SayEzbWait()

#18  

OK, DJ, this seems a good compromise. I wonder why it's so difficult to get a good sync between speech and mouth movement. Is it possible to make some improvement , or the PC itself, being a non-real-time system, makes the job difficult or even non possible ? Some hardware solution (connected to ezb speaker) might be better.

Thanks to merne, who suggested some test, that unfortunately didn't work.

#19  

@Lorn, I hope DJ's suggestion works. I also hope everything works out for you and don't give up Dj has made a great product.

You are welcome. Cheers

#20  

DJ suggestion is good . and it works. This way long sentences can be split into shorter ones making the setting process easier. Ezb is great. Using it you can give life to your robots with a few clicks, without using complex hardware and software. I'm asking DJ if some improvement in ezb software is planned , that might make talk servo work with any sentence, without the need to fine-tune everything each time you add a new sentence.

United Kingdom
#21  

@lornardo46 you should not need to fine tune every time you add a new sentence, once you have the settings right in the talk servo. The art is to break up long sentences into shorter ones in the script, using the sleep() command in-between, as JD has highlighted.

#22  

I solved my problem with the compromise, suggested by DJ, of splitting the long sentences. It's probably the only possible way without the use of extra hardware.