Revision history [back]

What is generating the comments in ROS messages?

When I run the command rosmsg show geometry_msgs/TwistStamped the output is

std_msgs/Header header
uint32 seq
time stamp
string frame_id
geometry_msgs/Twist twist
geometry_msgs/Vector3 linear
float64 x
float64 y
float64 z
geometry_msgs/Vector3 angular
float64 x
float64 y
float64 z


When I run rosmsg show --raw geometry_msgs/TwistStamped the output is

# A twist with reference coordinate frame and timestamp
Twist twist


When I run rosmsg show --raw geometry_msgs/TwistStamped --bag=<input.bag> I get the output of

# A twist with reference coordinate frame and timestamp
Twist twist
================================================================================
# Standard metadata for higher-level stamped data types.
# This is generally used to communicate timestamped data
# in a particular coordinate frame.
#
# sequence ID: consecutively increasing ID
uint32 seq
#Two-integer timestamp that is expressed as:
# * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called 'secs')
# * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called 'nsecs')
# time-handling sugar is provided by the client library
time stamp
#Frame this data is associated with
string frame_id

================================================================================
MSG: geometry_msgs/Twist
# This expresses velocity in free space broken into its linear and angular parts.
Vector3  linear
Vector3  angular
================================================================================
MSG: geometry_msgs/Vector3
# This represents a vector in free space.
# It is only meant to represent a direction. Therefore, it does not
# make sense to apply a translation to it (e.g., when applying a
# generic rigid transformation to a Vector3, tf2 will only apply the
# rotation). If you want your data to be translatable too, use the

This last example is also what I can see as the full text of a message in a debug session. Where are the comments coming from and who is generating them? I'm finding that some of my messages have all of the correct fields, but the comments are missing and many post-processing tools use the long line of ==== to parse through a message definition.