Macros | Functions | Variables
node.cpp File Reference
#include <ros/ros.h>
#include <sensor_msgs/NavSatFix.h>
#include <sensor_msgs/Imu.h>
#include <sensor_msgs/TimeReference.h>
#include <geometry_msgs/TwistWithCovarianceStamped.h>
#include <nav_msgs/Odometry.h>
#include <std_msgs/String.h>
#include <tf/LinearMath/Quaternion.h>
#include <tf/transform_datatypes.h>
#include "dispatch.h"
#include <gps_common/conversions.h>
#include <arpa/inet.h>
Include dependency graph for node.cpp:

Go to the source code of this file.

Macros

#define GPS_EPOCH_OFFSET   315964800
 
#define GPS_LEAP_SECONDS   18
 
#define OXFORD_DISPLAY_INFO   0
 
#define OXTS_INFO(...)   ROS_DEBUG(__VA_ARGS__)
 
#define OXTS_WARN(...)   ROS_DEBUG(__VA_ARGS__)
 
#define UINT16_MAX   (65535)
 

Functions

static void generateGGAString (double latitude, double longitude, double altitude, const ros::Time &utc_time, std::string &gga_msg)
 
static double getZoneMeridian (const std::string &utm_zone)
 
static void handlePacket (const Packet *packet, ros::Publisher &pub_fix, ros::Publisher &pub_vel, ros::Publisher &pub_imu, ros::Publisher &pub_odom, ros::Publisher &pub_pos_type, ros::Publisher &pub_nav_status, ros::Publisher &pub_gps_time_ref, ros::Publisher &pub_gga, const std::string &frame_id_gps, const std::string &frame_id_vel, const std::string &frame_id_odom)
 
int main (int argc, char **argv)
 
static void mapLookup (const std::map< uint8_t, std::string > &map, uint8_t key, std::string &val)
 
static bool openSocket (const std::string &interface, const std::string &ip_addr, uint16_t port, int *fd_ptr, sockaddr_in *sock_ptr)
 
static int readSocket (int fd, unsigned int timeout, void *data, size_t size, sockaddr *source_ptr=NULL)
 
static double SQUARE (double x)
 
static double toUtcTime (uint32_t gps_minutes, uint16_t gps_ms)
 

Variables

ros::Time g_gps_utc_time
 
static const std::map< uint8_t, std::string > NAV_STATUS_MAP
 
static const std::map< uint8_t, std::string > POS_MODE_MAP
 

Macro Definition Documentation

#define GPS_EPOCH_OFFSET   315964800

Definition at line 67 of file node.cpp.

#define GPS_LEAP_SECONDS   18

Definition at line 66 of file node.cpp.

#define OXFORD_DISPLAY_INFO   0

Definition at line 123 of file node.cpp.

#define OXTS_INFO (   ...)    ROS_DEBUG(__VA_ARGS__)

Definition at line 129 of file node.cpp.

#define OXTS_WARN (   ...)    ROS_DEBUG(__VA_ARGS__)

Definition at line 130 of file node.cpp.

#define UINT16_MAX   (65535)

Definition at line 61 of file node.cpp.

Function Documentation

static void generateGGAString ( double  latitude,
double  longitude,
double  altitude,
const ros::Time utc_time,
std::string &  gga_msg 
)
inlinestatic

Definition at line 197 of file node.cpp.

static double getZoneMeridian ( const std::string &  utm_zone)
inlinestatic

Definition at line 186 of file node.cpp.

static void handlePacket ( const Packet packet,
ros::Publisher pub_fix,
ros::Publisher pub_vel,
ros::Publisher pub_imu,
ros::Publisher pub_odom,
ros::Publisher pub_pos_type,
ros::Publisher pub_nav_status,
ros::Publisher pub_gps_time_ref,
ros::Publisher pub_gga,
const std::string &  frame_id_gps,
const std::string &  frame_id_vel,
const std::string &  frame_id_odom 
)
inlinestatic

Definition at line 245 of file node.cpp.

int main ( int  argc,
char **  argv 
)

Definition at line 511 of file node.cpp.

static void mapLookup ( const std::map< uint8_t, std::string > &  map,
uint8_t  key,
std::string &  val 
)
inlinestatic

Definition at line 177 of file node.cpp.

static bool openSocket ( const std::string &  interface,
const std::string &  ip_addr,
uint16_t  port,
int *  fd_ptr,
sockaddr_in *  sock_ptr 
)
inlinestatic

Definition at line 70 of file node.cpp.

static int readSocket ( int  fd,
unsigned int  timeout,
void *  data,
size_t  size,
sockaddr *  source_ptr = NULL 
)
inlinestatic

Definition at line 96 of file node.cpp.

static double SQUARE ( double  x)
inlinestatic

Definition at line 120 of file node.cpp.

static double toUtcTime ( uint32_t  gps_minutes,
uint16_t  gps_ms 
)
inlinestatic

Definition at line 192 of file node.cpp.

Variable Documentation

ros::Time g_gps_utc_time

Definition at line 65 of file node.cpp.

const std::map<uint8_t, std::string> NAV_STATUS_MAP
static
Initial value:
= {
{0, "INVALID"},
{1, "IMU_ONLY"},
{2, "INITIALIZING"},
{3, "LOCKING"},
{4, "READY"},
}

Definition at line 169 of file node.cpp.

const std::map<uint8_t, std::string> POS_MODE_MAP
static

Definition at line 133 of file node.cpp.



oxford_gps_eth
Author(s): Kevin Hallenbeck
autogenerated on Sun Aug 9 2020 04:05:34