ROSaic
|
The heart of the ROSaic driver: The ROS node that represents it. More...
#include <rosaic/node/rosaic_node.hpp>
Go to the source code of this file.
Functions | |
int | main (int argc, char **argv) |
Variables | |
bool | g_use_gnss_time |
bool | g_publish_gpst |
Whether or not to publish the sensor_msgs::TimeReference message with GPST. More... | |
bool | g_publish_navsatfix |
Whether or not to publish the sensor_msgs::NavSatFix message. More... | |
bool | g_publish_gpsfix |
Whether or not to publish the gps_common::GPSFix message. More... | |
bool | g_publish_pose |
Whether or not to publish the geometry_msgs::PoseWithCovarianceStamped message. More... | |
bool | g_publish_diagnostics |
Whether or not to publish the diagnostic_msgs::DiagnosticArray message. More... | |
std::string | g_frame_id |
The frame ID used in the header of every published ROS message. More... | |
uint32_t | g_leap_seconds |
The number of leap seconds that have been inserted into the UTC time. More... | |
boost::mutex | g_response_mutex |
Mutex to control changes of global variable "g_response_received". More... | |
bool | g_response_received |
Determines whether a command reply was received from the Rx. More... | |
boost::condition_variable | g_response_condition |
Condition variable complementing "g_response_mutex". More... | |
boost::mutex | g_cd_mutex |
Mutex to control changes of global variable "g_cd_received". More... | |
bool | g_cd_received |
Determines whether the connection descriptor was received from the Rx. More... | |
boost::condition_variable | g_cd_condition |
Condition variable complementing "g_cd_mutex". More... | |
bool | g_read_cd |
std::string | g_rx_tcp_port |
Rx TCP port, e.g. IP10 or IP11, to which ROSaic is connected to. More... | |
uint32_t | g_cd_count |
Since after SSSSSSSSSSS we need to wait for second connection descriptor, we have to count the connection descriptors. More... | |
bool | g_channelstatus_has_arrived_gpsfix |
For GPSFix: Whether the ChannelStatus block of the current epoch has arrived or not. More... | |
bool | g_measepoch_has_arrived_gpsfix |
For GPSFix: Whether the MeasEpoch block of the current epoch has arrived or not. More... | |
bool | g_dop_has_arrived_gpsfix |
For GPSFix: Whether the DOP block of the current epoch has arrived or not. More... | |
bool | g_pvtgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the PVTGeodetic block of the current epoch has arrived or not. More... | |
bool | g_poscovgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the PosCovGeodetic block of the current epoch has arrived or not. More... | |
bool | g_velcovgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the VelCovGeodetic block of the current epoch has arrived or not. More... | |
bool | g_atteuler_has_arrived_gpsfix |
For GPSFix: Whether the AttEuler block of the current epoch has arrived or not. More... | |
bool | g_attcoveuler_has_arrived_gpsfix |
For GPSFix: Whether the AttCovEuler block of the current epoch has arrived or not. More... | |
bool | g_pvtgeodetic_has_arrived_navsatfix |
For NavSatFix: Whether the PVTGeodetic block of the current epoch has arrived or not. More... | |
bool | g_poscovgeodetic_has_arrived_navsatfix |
For NavSatFix: Whether the PosCovGeodetic block of the current epoch has arrived or not. More... | |
bool | g_pvtgeodetic_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the PVTGeodetic block of the current epoch has arrived or not. More... | |
bool | g_poscovgeodetic_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the PosCovGeodetic block of the current epoch has arrived or not. More... | |
bool | g_atteuler_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the AttEuler block of the current epoch has arrived or not. More... | |
bool | g_attcoveuler_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the AttCovEuler block of the current epoch has arrived or not. More... | |
bool | g_receiverstatus_has_arrived_diagnostics |
For DiagnosticArray: Whether the ReceiverStatus block of the current epoch has arrived or not. More... | |
bool | g_qualityind_has_arrived_diagnostics |
For DiagnosticArray: Whether the QualityInd block of the current epoch has arrived or not. More... | |
std::map< std::string, uint32_t > | g_GPSFixMap |
A C++ map for keeping track of the SBF blocks necessary to construct the GPSFix ROS message. More... | |
std::map< std::string, uint32_t > | g_NavSatFixMap |
A C++ map for keeping track of the SBF blocks necessary to construct the NavSatFix ROS message. More... | |
std::map< std::string, uint32_t > | g_PoseWithCovarianceStampedMap |
A C++ map for keeping track of SBF blocks necessary to construct the PoseWithCovarianceStamped ROS message. More... | |
std::map< std::string, uint32_t > | g_DiagnosticArrayMap |
A C++ map for keeping track of SBF blocks necessary to construct the DiagnosticArray ROS message. More... | |
boost::shared_ptr< ros::NodeHandle > | g_nh |
const uint32_t | g_ROS_QUEUE_SIZE = 1 |
Queue size for ROS publishers. More... | |
The heart of the ROSaic driver: The ROS node that represents it.
Definition in file rosaic_node.cpp.
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 747 of file rosaic_node.cpp.
References g_attcoveuler_has_arrived_gpsfix, g_attcoveuler_has_arrived_pose, g_atteuler_has_arrived_gpsfix, g_atteuler_has_arrived_pose, g_cd_count, g_cd_received, g_channelstatus_has_arrived_gpsfix, g_dop_has_arrived_gpsfix, g_frame_id, g_leap_seconds, g_measepoch_has_arrived_gpsfix, g_nh, g_poscovgeodetic_has_arrived_gpsfix, g_poscovgeodetic_has_arrived_navsatfix, g_poscovgeodetic_has_arrived_pose, g_publish_diagnostics, g_publish_gpsfix, g_publish_gpst, g_publish_navsatfix, g_publish_pose, g_pvtgeodetic_has_arrived_gpsfix, g_pvtgeodetic_has_arrived_navsatfix, g_pvtgeodetic_has_arrived_pose, g_qualityind_has_arrived_diagnostics, g_read_cd, g_receiverstatus_has_arrived_diagnostics, g_response_received, g_use_gnss_time, g_velcovgeodetic_has_arrived_gpsfix, and rosaic_node::getROSInt().
bool g_attcoveuler_has_arrived_gpsfix |
For GPSFix: Whether the AttCovEuler block of the current epoch has arrived or not.
Definition at line 714 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_attcoveuler_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the AttCovEuler block of the current epoch has arrived or not.
Definition at line 726 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_atteuler_has_arrived_gpsfix |
For GPSFix: Whether the AttEuler block of the current epoch has arrived or not.
Definition at line 712 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_atteuler_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the AttEuler block of the current epoch has arrived or not.
Definition at line 724 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
boost::condition_variable g_cd_condition |
Condition variable complementing "g_cd_mutex".
Definition at line 691 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), and io_comm_rx::CallbackHandlers::readCallback().
uint32_t g_cd_count |
Since after SSSSSSSSSSS we need to wait for second connection descriptor, we have to count the connection descriptors.
Definition at line 698 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::next(), and io_comm_rx::CallbackHandlers::readCallback().
boost::mutex g_cd_mutex |
Mutex to control changes of global variable "g_cd_received".
Definition at line 687 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_cd_received |
Determines whether the connection descriptor was received from the Rx.
Definition at line 689 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), main(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_channelstatus_has_arrived_gpsfix |
For GPSFix: Whether the ChannelStatus block of the current epoch has arrived or not.
Definition at line 700 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
std::map<std::string, uint32_t> g_DiagnosticArrayMap |
A C++ map for keeping track of SBF blocks necessary to construct the DiagnosticArray ROS message.
Definition at line 738 of file rosaic_node.cpp.
bool g_dop_has_arrived_gpsfix |
For GPSFix: Whether the DOP block of the current epoch has arrived or not.
Definition at line 704 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
std::string g_frame_id |
The frame ID used in the header of every published ROS message.
Definition at line 677 of file rosaic_node.cpp.
Referenced by main(), GpgsaParser::parseASCII(), GpgsvParser::parseASCII(), GprmcParser::parseASCII(), GpggaParser::parseASCII(), and io_comm_rx::RxMessage::read().
std::map<std::string, uint32_t> g_GPSFixMap |
A C++ map for keeping track of the SBF blocks necessary to construct the GPSFix ROS message.
Definition at line 732 of file rosaic_node.cpp.
uint32_t g_leap_seconds |
The number of leap seconds that have been inserted into the UTC time.
Definition at line 679 of file rosaic_node.cpp.
Referenced by main(), and io_comm_rx::timestampSBF().
bool g_measepoch_has_arrived_gpsfix |
For GPSFix: Whether the MeasEpoch block of the current epoch has arrived or not.
Definition at line 702 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
std::map<std::string, uint32_t> g_NavSatFixMap |
A C++ map for keeping track of the SBF blocks necessary to construct the NavSatFix ROS message.
Definition at line 734 of file rosaic_node.cpp.
boost::shared_ptr<ros::NodeHandle> g_nh |
Node Handle for the ROSaic node You must initialize the NodeHandle in the "main" function (or in any method called indirectly or directly by the main function). One can declare a pointer to the NodeHandle to be a global variable and then initialize it afterwards only...
Definition at line 743 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::connect(), rosaic_node::getROSInt(), rosaic_node::ROSaicNode::getROSParams(), main(), and io_comm_rx::RxMessage::read().
bool g_poscovgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the PosCovGeodetic block of the current epoch has arrived or not.
Definition at line 708 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_poscovgeodetic_has_arrived_navsatfix |
For NavSatFix: Whether the PosCovGeodetic block of the current epoch has arrived or not.
Definition at line 718 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_poscovgeodetic_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the PosCovGeodetic block of the current epoch has arrived or not.
Definition at line 722 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
std::map<std::string, uint32_t> g_PoseWithCovarianceStampedMap |
A C++ map for keeping track of SBF blocks necessary to construct the PoseWithCovarianceStamped ROS message.
Definition at line 736 of file rosaic_node.cpp.
bool g_publish_diagnostics |
Whether or not to publish the diagnostic_msgs::DiagnosticArray message.
Definition at line 675 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), rosaic_node::ROSaicNode::defineMessages(), io_comm_rx::CallbackHandlers::handle(), main(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_publish_gpsfix |
Whether or not to publish the gps_common::GPSFix message.
Definition at line 671 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), rosaic_node::ROSaicNode::defineMessages(), io_comm_rx::CallbackHandlers::handle(), main(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_publish_gpst |
Whether or not to publish the sensor_msgs::TimeReference message with GPST.
Definition at line 667 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::defineMessages(), io_comm_rx::CallbackHandlers::handle(), and main().
bool g_publish_navsatfix |
Whether or not to publish the sensor_msgs::NavSatFix message.
Definition at line 669 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::defineMessages(), io_comm_rx::CallbackHandlers::handle(), main(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_publish_pose |
Whether or not to publish the geometry_msgs::PoseWithCovarianceStamped message.
Definition at line 673 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::defineMessages(), io_comm_rx::CallbackHandlers::handle(), main(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_pvtgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the PVTGeodetic block of the current epoch has arrived or not.
Definition at line 706 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_pvtgeodetic_has_arrived_navsatfix |
For NavSatFix: Whether the PVTGeodetic block of the current epoch has arrived or not.
Definition at line 716 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_pvtgeodetic_has_arrived_pose |
For PoseWithCovarianceStamped: Whether the PVTGeodetic block of the current epoch has arrived or not.
Definition at line 720 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_qualityind_has_arrived_diagnostics |
For DiagnosticArray: Whether the QualityInd block of the current epoch has arrived or not.
Definition at line 730 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_read_cd |
Whether or not we still want to read the connection descriptor, which we only want in the very beginning to know whether it is IP10, IP11 etc.
Definition at line 694 of file rosaic_node.cpp.
Referenced by io_comm_rx::RxMessage::found(), main(), io_comm_rx::RxMessage::next(), and io_comm_rx::RxMessage::search().
bool g_receiverstatus_has_arrived_diagnostics |
For DiagnosticArray: Whether the ReceiverStatus block of the current epoch has arrived or not.
Definition at line 728 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().
boost::condition_variable g_response_condition |
Condition variable complementing "g_response_mutex".
Definition at line 685 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), and io_comm_rx::CallbackHandlers::readCallback().
boost::mutex g_response_mutex |
Mutex to control changes of global variable "g_response_received".
Definition at line 681 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_response_received |
Determines whether a command reply was received from the Rx.
Definition at line 683 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), main(), and io_comm_rx::CallbackHandlers::readCallback().
const uint32_t g_ROS_QUEUE_SIZE = 1 |
Queue size for ROS publishers.
Definition at line 745 of file rosaic_node.cpp.
Referenced by io_comm_rx::RxMessage::read().
std::string g_rx_tcp_port |
Rx TCP port, e.g. IP10 or IP11, to which ROSaic is connected to.
Definition at line 696 of file rosaic_node.cpp.
Referenced by rosaic_node::ROSaicNode::configureRx(), and io_comm_rx::CallbackHandlers::readCallback().
bool g_use_gnss_time |
If true, the ROS message headers' unix time field is constructed from the TOW (in the SBF case) and UTC (in the NMEA case) data. If false, times are constructed within the driver via time(NULL) of the <ctime> library.
Definition at line 665 of file rosaic_node.cpp.
Referenced by main(), GprmcParser::parseASCII(), GpggaParser::parseASCII(), and io_comm_rx::RxMessage::read().
bool g_velcovgeodetic_has_arrived_gpsfix |
For GPSFix: Whether the VelCovGeodetic block of the current epoch has arrived or not.
Definition at line 710 of file rosaic_node.cpp.
Referenced by main(), io_comm_rx::RxMessage::read(), and io_comm_rx::CallbackHandlers::readCallback().