31 #include <semaphore.h> 33 #include <libplayercore/playercore.h> 71 int first_goal_has_been_set_to_init_position;
77 std::vector<double> laser__ranges;
78 double laser__resolution;
79 double laser__max_range;
80 uint32_t laser__ranges_count;
84 double obstacle_avoid_dist;
87 double goal_position_tol;
88 double goal_angle_tol;
89 double goalX,goalY,goalA;
90 pthread_t algorithm_thread;
91 pthread_mutex_t goal_mutex;
92 pthread_cond_t goal_changed_cond;
94 pthread_mutex_t data_mutex;
95 pthread_cond_t data_changed_cond;
97 int data_odometry_ready;
100 void WaitForNextGoal();
101 void SignalNextGoal(
double goalX,
double goalY,
double goalA);
103 void ReadIfWaiting();
113 double GetScanRes() ;
114 double GetMaxRange() ;
115 uint32_t GetCount() ;
116 double range(
const int index);
118 void SetMotorEnable(
int turnkey);
119 void SetOdometry(
double position_x0,
121 double position_alpha0);
126 void SetSpeed(
double velocity_modulus,
127 double velocity_angle);
137 extern "C" int player_driver_init(DriverTable* table);
Class for loading configuration file information.
Definition: configfile.h:196
position 2d velocity command
Definition: player_interfaces.h:617
Generic message header.
Definition: player.h:161
virtual int Setup()
Initialize the driver.
Definition: snd.cc:307
A pose in the plane.
Definition: player.h:217
virtual void Main()
Main method for driver thread.
Definition: snd.cc:343
A device address.
Definition: player.h:145
Base class for drivers which oeprate with a thread.
Definition: driver.h:552
position2d geom
Definition: player_interfaces.h:655
Encapsulates a device (i.e., a driver bound to an interface)
Definition: device.h:74
An autopointer for the message queue.
Definition: message.h:73
virtual int ProcessMessage(QueuePointer &resp_queue, player_msghdr *hdr, void *data)
Message handler.
Definition: snd.cc:423
virtual int Shutdown()
Finalize the driver.
Definition: snd.cc:325