icub-client
ears.h
Go to the documentation of this file.
1 #ifndef EARS_H
2 #define EARS_H
3 
4 #include <yarp/os/RFModule.h>
5 #include <yarp/os/Port.h>
6 
7 namespace icubclient {
8  class ICubClient;
9 }
10 
14 class ears : public yarp::os::RFModule {
15 protected:
17  double period;
18  yarp::os::Port rpc;
19  yarp::os::Port portToBehavior;
20  yarp::os::Port portToSpeechRecognizer;
21  yarp::os::Mutex m;
23  std::string MainGrammar;
24 
25 public:
26  bool configure(yarp::os::ResourceFinder &rf);
27 
28  bool interruptModule();
29 
30  bool close();
31 
32  double getPeriod()
33  {
34  return period;
35  }
36 
37  bool updateModule();
38 
39  //RPC & scenarios
40  bool respond(const yarp::os::Bottle& cmd, yarp::os::Bottle& reply);
41 };
42 
43 #endif
Grants access to high level motor commands (grasp, touch, look, goto, etc) of the robot as well as it...
Definition: icubClient.h:66
yarp::os::Port portToBehavior
Port to behaviorManager.
Definition: ears.h:19
yarp::os::Port portToSpeechRecognizer
Port to speechRecognizer.
Definition: ears.h:20
Definition: ears.h:14
double period
Definition: ears.h:17
bool bShouldListen
Whether ears should listen to speechRecognizer.
Definition: ears.h:22
yarp::os::Mutex m
Mutex indicating whether ears is listening to speechRecognizer.
Definition: ears.h:21
yarp::os::Port rpc
Response port.
Definition: ears.h:18
double getPeriod()
Definition: ears.h:32
std::string MainGrammar
Name of grammar to be loaded.
Definition: ears.h:23
icubclient::ICubClient * iCub
Definition: ears.h:16