Tetrapod Project
|
A class for logging utilities. More...
#include <log_utils.h>
Public Member Functions | |
LogUtils () | |
Constructor. More... | |
virtual | ~LogUtils () |
Destructor. More... | |
void | WriteToLog () |
void | OnGenCoordMsg (const std_msgs::Float64MultiArrayConstPtr &_msg) |
The OnGenCoordMsg function handles an incoming generalized coordinates message from ROS. More... | |
void | OnGenVelMsg (const std_msgs::Float64MultiArrayConstPtr &_msg) |
The OnGenVelMsg function handles an incoming generalized velocities message from ROS. More... | |
void | OnJointStateMsg (const sensor_msgs::JointStateConstPtr &_msg) |
The OnJointStateMsg function handles an incoming joint state message from ROS. More... | |
void | OnJointStateCmdMsg (const sensor_msgs::JointStateConstPtr &_msg) |
The OnJointStateCmdMsg function handles an incoming joint state command message from ROS. More... | |
void | PublishQueueThread () |
The PublishQueueThread function is a ROS helper function that publish state messages. More... | |
void | ProcessQueueThread () |
The ProcessQueueThread function is a ROS helper function that processes messages. More... | |
Protected Member Functions | |
void | InitRos () |
The InitRos function is called to initialize ROS. More... | |
void | InitRosQueueThreads () |
The InitRosQueueThreads function is called to initialize the ROS Publish and Process Queue Threads. More... | |
Private Attributes | |
Kinematics | kinematics |
Kinematics. More... | |
Eigen::Matrix< double, 18, 1 > | genCoord |
Generalized Coordinates. More... | |
Eigen::Matrix< double, 18, 1 > | genVel |
Generalized Velocities. More... | |
sensor_msgs::JointState | jointState |
Joint State. More... | |
sensor_msgs::JointState | jointStateCmd |
Joint State Command. More... | |
Eigen::Matrix< Eigen::Vector3d, 4, 1 > | fPos |
Footstep positions. More... | |
int | contactState [4] |
Contact State. More... | |
std::unique_ptr< ros::NodeHandle > | rosNode |
Node used for ROS transport. More... | |
ros::Subscriber | genCoordSub |
ROS Generalized Coordinates Subscriber. More... | |
ros::Subscriber | genVelSub |
ROS Generalized Coordinates Subscriber. More... | |
ros::Subscriber | jointStateSub |
ROS Joint State Subscriber. More... | |
ros::Subscriber | jointStateCmdSub |
ROS Joint State Command Subscriber. More... | |
ros::Subscriber | contactStateSub |
ROS Contact State Subscriber. More... | |
ros::Publisher | genCoordLogPub |
ROS Generalized Coordinates Log Publisher. More... | |
ros::Publisher | genVelLogPub |
ROS Generalized Velocities Log Publisher. More... | |
ros::Publisher | jointStatePub |
ROS Joint State Log Publisher. More... | |
ros::Publisher | jointStateCmdPub |
ROS Joint State Command Log Publisher. More... | |
ros::CallbackQueue | rosPublishQueue |
ROS callbackque that helps publish messages. More... | |
ros::CallbackQueue | rosProcessQueue |
ROS callbackque that helps process messages. More... | |
std::thread | rosPublishQueueThread |
Thread running the rosPublishQueue. More... | |
std::thread | rosProcessQueueThread |
Thread running the rosProcessQueue. More... | |
A class for logging utilities.
Definition at line 48 of file log_utils.h.
LogUtils::LogUtils | ( | ) |
Constructor.
Definition at line 30 of file log_utils.cpp.
|
virtual |
Destructor.
Definition at line 43 of file log_utils.cpp.
void LogUtils::WriteToLog | ( | ) |
Definition at line 57 of file log_utils.cpp.
void LogUtils::OnGenCoordMsg | ( | const std_msgs::Float64MultiArrayConstPtr & | _msg | ) |
The OnGenCoordMsg function handles an incoming generalized coordinates message from ROS.
[in] | _msg | A float array containing the generalized coordinates. |
Definition at line 69 of file log_utils.cpp.
void LogUtils::OnGenVelMsg | ( | const std_msgs::Float64MultiArrayConstPtr & | _msg | ) |
The OnGenVelMsg function handles an incoming generalized velocities message from ROS.
[in] | _msg | A float array containing the generalized velocities. |
Definition at line 87 of file log_utils.cpp.
void LogUtils::OnJointStateMsg | ( | const sensor_msgs::JointStateConstPtr & | _msg | ) |
The OnJointStateMsg function handles an incoming joint state message from ROS.
[in] | _msg | A message holding data to describe the state of a set of controlled joints. The state is defined by
|
Definition at line 96 of file log_utils.cpp.
void LogUtils::OnJointStateCmdMsg | ( | const sensor_msgs::JointStateConstPtr & | _msg | ) |
The OnJointStateCmdMsg function handles an incoming joint state command message from ROS.
[in] | _msg | A message holding data to describe the state of a set of controlled joints. The state is defined by
|
Definition at line 105 of file log_utils.cpp.
void LogUtils::PublishQueueThread | ( | ) |
The PublishQueueThread function is a ROS helper function that publish state messages.
Definition at line 114 of file log_utils.cpp.
void LogUtils::ProcessQueueThread | ( | ) |
The ProcessQueueThread function is a ROS helper function that processes messages.
Definition at line 124 of file log_utils.cpp.
|
protected |
The InitRos function is called to initialize ROS.
Definition at line 134 of file log_utils.cpp.
|
protected |
The InitRosQueueThreads function is called to initialize the ROS Publish and Process Queue Threads.
Definition at line 245 of file log_utils.cpp.
|
private |
Definition at line 105 of file log_utils.h.
|
private |
Generalized Coordinates.
Definition at line 108 of file log_utils.h.
|
private |
Generalized Velocities.
Definition at line 111 of file log_utils.h.
|
private |
Joint State.
Definition at line 114 of file log_utils.h.
|
private |
Joint State Command.
Definition at line 117 of file log_utils.h.
|
private |
Footstep positions.
Definition at line 120 of file log_utils.h.
|
private |
Contact State.
Definition at line 123 of file log_utils.h.
|
private |
Node used for ROS transport.
Definition at line 126 of file log_utils.h.
|
private |
ROS Generalized Coordinates Subscriber.
Definition at line 129 of file log_utils.h.
|
private |
ROS Generalized Coordinates Subscriber.
Definition at line 132 of file log_utils.h.
|
private |
ROS Joint State Subscriber.
Definition at line 135 of file log_utils.h.
|
private |
ROS Joint State Command Subscriber.
Definition at line 138 of file log_utils.h.
|
private |
ROS Contact State Subscriber.
Definition at line 141 of file log_utils.h.
|
private |
ROS Generalized Coordinates Log Publisher.
Definition at line 144 of file log_utils.h.
|
private |
ROS Generalized Velocities Log Publisher.
Definition at line 147 of file log_utils.h.
|
private |
ROS Joint State Log Publisher.
Definition at line 150 of file log_utils.h.
|
private |
ROS Joint State Command Log Publisher.
Definition at line 153 of file log_utils.h.
|
private |
ROS callbackque that helps publish messages.
Definition at line 156 of file log_utils.h.
|
private |
ROS callbackque that helps process messages.
Definition at line 159 of file log_utils.h.
|
private |
Thread running the rosPublishQueue.
Definition at line 162 of file log_utils.h.
|
private |
Thread running the rosProcessQueue.
Definition at line 165 of file log_utils.h.