AdaptiveMCL Class Reference
Inheritance diagram for AdaptiveMCL:
Collaboration diagram for AdaptiveMCL:

List of all members.

Public Member Functions

 AdaptiveMCL (ConfigFile *cf, int section)
virtual int MainSetup (void)
 Sets up the resources needed by the driver thread.
void Push (AMCLSensorData *data)
virtual int ProcessMessage (QueuePointer &resp_queue, player_msghdr *hdr, void *data)
 Message handler.
virtual void UpdateSensorData (void)

Private Member Functions

AMCLSensorDataPeek (void)
AMCLSensorDataPop (void)
virtual void Main (void)
 Main method for driver thread.
virtual void MainQuit ()
 Cleanup method for driver thread (called when main exits)
void InitFilter (void)
bool UpdateFilter ()
void PutDataLocalize (double time)
void PutDataPosition (pf_vector_t delta, double time)
void ProcessGeom (QueuePointer &resp_queue, player_msghdr_t *hdr)

Private Attributes

player_devaddr_t position_addr
player_devaddr_t localize_addr
int sensor_count
AMCLSensorsensors [16]
int init_sensor
int action_sensor
int pf_min_samples
int pf_max_samples
double pf_err
double pf_z
int q_size
int q_start
int q_len
AMCLSensorData ** q_data
int hyp_count
int hyp_alloc
pf_vector_t best_hyp
pthread_mutex_t best_hyp_lock
bool pf_init
bool pf_init_internal
pf_vector_t pf_init_pose_mean
pf_matrix_t pf_init_pose_cov
pf_vector_t pf_odom_pose
double min_dr
double min_da

Member Function Documentation

void AdaptiveMCL::Main ( void  ) [private, virtual]

Main method for driver thread.

drivers have their own thread of execution, created using StartThread(); this is the entry point for the driver thread, and must be overloaded by all threaded drivers.

Implements ThreadedDriver.

References Driver::ProcessMessages().

Here is the call graph for this function:

void AdaptiveMCL::MainQuit ( void  ) [private, virtual]

Cleanup method for driver thread (called when main exits)

Overload this method and to do additional cleanup when the driver thread exits.

Reimplemented from ThreadedDriver.

References PLAYER_MSG0, and ThreadedDriver::Shutdown().

Here is the call graph for this function:

int AdaptiveMCL::ProcessMessage ( QueuePointer resp_queue,
player_msghdr hdr,
void *  data 
) [virtual]

Message handler.

This function is called once for each message in the incoming queue. Reimplement it to provide message handling. Return 0 if you handled the message and -1 otherwise

resp_queueThe queue to which any response should go.
hdrThe message header
dataThe message body

Reimplemented from Driver.

References player_localize_particle::alpha, player_localize_set_pose::cov, Driver::device_addr, Message::MatchMessage(), player_localize_get_particles::mean, player_localize_set_pose::mean, player_pose2d::pa, player_localize_get_particles::particles, player_localize_get_particles::particles_count, PLAYER_LOCALIZE_REQ_GET_PARTICLES, PLAYER_LOCALIZE_REQ_SET_POSE, PLAYER_MSGTYPE_REQ, PLAYER_MSGTYPE_RESP_ACK, PLAYER_POSITION2D_REQ_GET_GEOM, player_localize_particle::pose, Driver::Publish(), player_pose2d::px, player_pose2d::py, player_msghdr::size, and player_localize_get_particles::variance.

Here is the call graph for this function:

The documentation for this class was generated from the following files: