
Tymtravler
I have a bunch of (say) fields setup in VR. If someone just happens to say something that is close to one of my say commands JAC will shoot off his mouth. I was wondering if there is a way for me to tell the robot not say anything until I want him to. I have a HAL9000 Home Automated System that I can tell it to go to sleep("Computer Go To Sleep"). It will still listen but will not responded to any commands until I tell it to wake up("Computer Wake Up". Then it will respond to my spoken command.
"please turn on the Lights" rather than just "Lights"
You can also make some commands into toggles rather than have two separate commands.
Eg. One command saying "Computer lights please" instead of having two separate commands "Turn the lights on" and "Turn the lights off".
Your program would look something like:
#Define Variables
$Lights=""
# Toggle the lights
if ($Lights="Off" )
$Lights=("On" )
$Phrase=("Lights activated" )
elseif ($Lights="On" )
$Lights=("Off" )
$Phrase=("Lights de-activated" )
endif
cc("Speech Recognition", PauseMS, 3000)
Say ("$Phrase" )
Notice I also pause the recognition while speaking...seems to reduce errors.
I sometimes also use saywait("Lights de-activated") to prevent anything else happening until the statement has been spoken.
@Tameion
i.e.
Code:
The servo wont move until after the speech is finished.
Whereas
Code:
The servo will move while the phrase is being said.
And just to clarify, Say/SayWait are commands for the robot to speak, not for the robot to listen.
WaitForSpeech is for the robot to listen.
http://www.ez-robot.com/Community/Forum/posts.aspx?threadId=2263
I'm on vacation on a carabeian island right now and having difcuilty posting so if this didn't cone through properly will someone please correct the link?
Thanks Dave
EDIT:
OK, I'm at a better computer now so here's a easier link to follow:
www.ez-robot.com/Community/Forum/posts.aspx?threadId=2263
Take a peek at a few of my vids and you'll see where I tell him to stop listening and start listening. I'll say "Be Quiet Ninny" and "Pay attention my dear friend" to do each. Really comes in handy when he starts reacting to things he shouldn't when me or other people are talking around him.
In addition you can add a SR pause in the SR command it's self. That way he wont react to things he is saying himself. Before DJ added this upgrade my robot would sometimes chatter on and on reacting to different things he would say himself. It would go on forever sometimes till I shut it off. It was kinda spooky. Like he had a split personality and would have conversations with him self.
*eek*
Enjoy your well deserved vacation! Next time being me
@DJ , Sorry, didn't mean to seem aloof or snobby. However this should tell you something about your product. While sitting on a white sand beach with blue water I'll spend time reading this forum and thinking about EZB robots. I even plan to work on cleaning up my B9 project this week from the beach chair. Maybe.... Damm, I just messed a little red bikini walk past...... OK, I'm outa here. Time to order a beer and watch the beach.
@dschulpius - I'm officially mad at you for 1 day. Enjoy your vacation lucky ducky.