#include <stdlib.h>
#include <stdio.h>
#include <string>
#include <vector>
#include <ros/ros.h>
#include <tf/transform_broadcaster.h>
#include <nav_msgs/Odometry.h>
#include <geometry_msgs/Twist.h>
#include <cereal_port/CerealPort.h>
Go to the source code of this file.
Defines | |
#define | AXLE_LENGTH 0.225 |
#define | MAX_ENCODER_COUNT 32768 |
#define | NORMALIZE(z) atan2(sin(z), cos(z)) |
#define | PULSES_TO_M 0.000073529 |
Functions | |
void | cmdVelReceived (const geometry_msgs::Twist::ConstPtr &cmd_vel) |
std::string | drive (double linear_speed, double angular_speed, int ID_Robot) |
int | main (int argc, char **argv) |
void | robotDataCallback (std::string *data) |
bool | signof (int n) |
Variables | |
bool | confirm_communication = true |
ros::Time | current_time |
int | ID_Robot = 0 |
ros::Time | last_time |
double | last_time_pub = 0.0 |
int | left_encoder_prev = 0 |
tf::TransformBroadcaster * | odom_broadcaster_ptr |
ros::Publisher * | odom_pub_ptr |
double | odometry_x_ = 0.0 |
double | odometry_y_ = 0.0 |
double | odometry_yaw_ = 0.0 |
int | right_encoder_prev = 0 |
cereal::CerealPort | serial_port |
#define AXLE_LENGTH 0.225 |
Definition at line 17 of file stingbot_node.cpp.
#define MAX_ENCODER_COUNT 32768 |
Definition at line 15 of file stingbot_node.cpp.
#define PULSES_TO_M 0.000073529 |
Definition at line 18 of file stingbot_node.cpp.
void cmdVelReceived | ( | const geometry_msgs::Twist::ConstPtr & | cmd_vel | ) |
Definition at line 198 of file stingbot_node.cpp.
std::string drive | ( | double | linear_speed, |
double | angular_speed, | ||
int | ID_Robot | ||
) |
Definition at line 176 of file stingbot_node.cpp.
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 206 of file stingbot_node.cpp.
void robotDataCallback | ( | std::string * | data | ) |
Definition at line 44 of file stingbot_node.cpp.
bool signof | ( | int | n | ) |
Definition at line 32 of file stingbot_node.cpp.
bool confirm_communication = true |
Definition at line 33 of file stingbot_node.cpp.
Definition at line 29 of file stingbot_node.cpp.
int ID_Robot = 0 |
Definition at line 34 of file stingbot_node.cpp.
Definition at line 29 of file stingbot_node.cpp.
double last_time_pub = 0.0 |
Definition at line 30 of file stingbot_node.cpp.
int left_encoder_prev = 0 |
Definition at line 40 of file stingbot_node.cpp.
Definition at line 26 of file stingbot_node.cpp.
Definition at line 25 of file stingbot_node.cpp.
double odometry_x_ = 0.0 |
Definition at line 36 of file stingbot_node.cpp.
double odometry_y_ = 0.0 |
Definition at line 37 of file stingbot_node.cpp.
double odometry_yaw_ = 0.0 |
Definition at line 38 of file stingbot_node.cpp.
int right_encoder_prev = 0 |
Definition at line 39 of file stingbot_node.cpp.
Definition at line 28 of file stingbot_node.cpp.