Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes
ublox_gps::Gps Class Reference

#include <gps.h>

List of all members.

Public Member Functions

void close ()
bool configure ()
template<typename ConfigT >
bool configure (const ConfigT &message, bool wait=true)
bool enableSBAS (bool onoff)
 Gps ()
template<typename StreamT >
void initialize (StreamT &stream, boost::asio::io_service &io_service)
void initialize (const boost::shared_ptr< Worker > &worker)
template<>
void initialize (boost::asio::serial_port &serial_port, boost::asio::io_service &io_service)
bool isConfigured () const
bool isInitialized () const
template<typename ConfigT >
bool poll (ConfigT &message, const boost::posix_time::time_duration &timeout=default_timeout_)
bool poll (uint8_t class_id, uint8_t message_id, const std::vector< uint8_t > &payload=std::vector< uint8_t >())
template<typename T >
bool read (T &message, const boost::posix_time::time_duration &timeout=default_timeout_)
bool setBaudrate (unsigned int baudrate)
bool setRate (uint8_t class_id, uint8_t message_id, unsigned int rate)
template<typename T >
Callbacks::iterator subscribe (typename CallbackHandler_< T >::Callback callback, unsigned int rate)
template<typename T >
Callbacks::iterator subscribe (typename CallbackHandler_< T >::Callback callback)
void waitForAcknowledge (const boost::posix_time::time_duration &timeout)
virtual ~Gps ()

Private Types

enum  { WAIT, ACK, NACK }

Private Member Functions

void readCallback (unsigned char *data, std::size_t &size)

Private Attributes

enum ublox_gps::Gps:: { ... }  acknowledge_
unsigned int baudrate_
boost::mutex callback_mutex_
Callbacks callbacks_
bool configured_
boost::shared_ptr< Workerworker_

Static Private Attributes

static
boost::posix_time::time_duration 
default_timeout_

Detailed Description

Definition at line 42 of file gps.h.


Member Enumeration Documentation

anonymous enum [private]
Enumerator:
WAIT 
ACK 
NACK 

Definition at line 76 of file gps.h.


Constructor & Destructor Documentation

Definition at line 37 of file gps.cpp.

ublox_gps::Gps::~Gps ( ) [virtual]

Definition at line 43 of file gps.cpp.


Member Function Documentation

Definition at line 115 of file gps.cpp.

Definition at line 149 of file gps.cpp.

template<typename ConfigT >
bool ublox_gps::Gps::configure ( const ConfigT &  message,
bool  wait = true 
)

Definition at line 152 of file gps.h.

bool ublox_gps::Gps::enableSBAS ( bool  onoff)

Definition at line 130 of file gps.cpp.

template<typename StreamT >
void ublox_gps::Gps::initialize ( StreamT &  stream,
boost::asio::io_service &  io_service 
)

Definition at line 85 of file gps.h.

void ublox_gps::Gps::initialize ( const boost::shared_ptr< Worker > &  worker)

Definition at line 63 of file gps.cpp.

void ublox_gps::Gps::initialize ( boost::asio::serial_port &  serial_port,
boost::asio::io_service &  io_service 
)

Definition at line 75 of file gps.cpp.

bool ublox_gps::Gps::isConfigured ( ) const [inline]

Definition at line 63 of file gps.h.

bool ublox_gps::Gps::isInitialized ( ) const [inline]

Definition at line 62 of file gps.h.

template<typename ConfigT >
bool ublox_gps::Gps::poll ( ConfigT &  message,
const boost::posix_time::time_duration &  timeout = default_timeout_ 
)

Definition at line 127 of file gps.h.

bool ublox_gps::Gps::poll ( uint8_t  class_id,
uint8_t  message_id,
const std::vector< uint8_t > &  payload = std::vector<uint8_t>() 
)

Definition at line 138 of file gps.cpp.

template<typename T >
bool ublox_gps::Gps::read ( T &  message,
const boost::posix_time::time_duration &  timeout = default_timeout_ 
)

Definition at line 132 of file gps.h.

void ublox_gps::Gps::readCallback ( unsigned char *  data,
std::size_t &  size 
) [private]

Definition at line 185 of file gps.cpp.

bool ublox_gps::Gps::setBaudrate ( unsigned int  baudrate)

Definition at line 48 of file gps.cpp.

bool ublox_gps::Gps::setRate ( uint8_t  class_id,
uint8_t  message_id,
unsigned int  rate 
)

Definition at line 121 of file gps.cpp.

template<typename T >
Callbacks::iterator ublox_gps::Gps::subscribe ( typename CallbackHandler_< T >::Callback  callback,
unsigned int  rate 
)

Definition at line 96 of file gps.h.

template<typename T >
Callbacks::iterator ublox_gps::Gps::subscribe ( typename CallbackHandler_< T >::Callback  callback)

Definition at line 103 of file gps.h.

void ublox_gps::Gps::waitForAcknowledge ( const boost::posix_time::time_duration &  timeout)

Definition at line 177 of file gps.cpp.


Member Data Documentation

enum { ... } ublox_gps::Gps::acknowledge_ [private]
unsigned int ublox_gps::Gps::baudrate_ [private]

Definition at line 77 of file gps.h.

boost::mutex ublox_gps::Gps::callback_mutex_ [private]

Definition at line 81 of file gps.h.

Definition at line 80 of file gps.h.

Definition at line 75 of file gps.h.

boost::posix_time::time_duration ublox_gps::Gps::default_timeout_ [static, private]

Definition at line 78 of file gps.h.

boost::shared_ptr<Worker> ublox_gps::Gps::worker_ [private]

Definition at line 74 of file gps.h.


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


ublox_gps
Author(s): Johannes Meyer
autogenerated on Mon Oct 6 2014 08:16:41