0

Is there a way to execute multiple applications at the same time or one of my applications to call another one. For example lets say I have one application, that is just a dialog only. Also the basic speech (http://doc.aldebaran.com/2-1/nao/basic_channel_conversation.html) is installed also on my robot.

  1. Is there a way my robot to be able to use the defined phrases in the basic speech and the phrases defined in my application simultaneously?

  2. Is there a way my application to call this basic speech without quiting my application

  3. Is there a way to run multiple application I have created in parallel?

Currently when my app is running, Pepper doesn't understand anything from the basic speech, but I want to use it because I like it.

stefan.stt
  • 2,357
  • 5
  • 24
  • 47

2 Answers2

2

Use the behavior manager to run other applications from within your main app. http://doc.aldebaran.com/2-5/naoqi/core/albehaviormanager.html

E.g.

self.behaviorManager = self.session.service("ALBehaviorManager")
self.behaviorManager.runBehavior("System/animations/Stand/Reactions/SeeSomething_1")

So you might want to call runBehavior("usr/run_dialog_dev") when a human is detected.

Anders_K
  • 982
  • 9
  • 28
1

Is there a way my robot to be able to use the defined phrases in the basic speech and the phrases defined in my application simultaneously?

If you want to add your sentences to the basic speech, you can use collaborative dialogs and even start your app on demand with the command ^switchFocus(my-app/my-behavior). All topics (from all apps) that are defined as "collaborative dialogs" will be loaded when the "basic speech" starts. Be careful that only the topic is started, not the app it comes from!

Is there a way my application to call this basic speech without quiting my application

You can use ALDialog.runDialog (doc here) but you need to think how to go back and forth between your application topic and the basic general topics.

Example: when Pepper wants to present different products, what happens after you ask "What time is it?", the robot answers and is now off-topic, but then what? you will need to find a way to drive the user back into topic!

Is there a way to run multiple application I have created in parallel?

runBehavior will do the trick yes, but be careful that the concurrent behaviors won't make the robot do two things at the same time (movements for example). A better architecture would be to have a collaborative dialog that switches focus to the right application to answer, then goes back to the general basic speech.

JLS
  • 968
  • 5
  • 12