00001
00002 #ifndef NXT_MSGS_MESSAGE_ACCELEROMETER_H
00003 #define NXT_MSGS_MESSAGE_ACCELEROMETER_H
00004 #include <string>
00005 #include <vector>
00006 #include <ostream>
00007 #include "ros/serialization.h"
00008 #include "ros/builtin_message_traits.h"
00009 #include "ros/message_operations.h"
00010 #include "ros/message.h"
00011 #include "ros/time.h"
00012
00013 #include "std_msgs/Header.h"
00014 #include "geometry_msgs/Vector3.h"
00015
00016 namespace nxt_msgs
00017 {
00018 template <class ContainerAllocator>
00019 struct Accelerometer_ : public ros::Message
00020 {
00021 typedef Accelerometer_<ContainerAllocator> Type;
00022
00023 Accelerometer_()
00024 : header()
00025 , linear_acceleration()
00026 , linear_acceleration_covariance()
00027 {
00028 linear_acceleration_covariance.assign(0.0);
00029 }
00030
00031 Accelerometer_(const ContainerAllocator& _alloc)
00032 : header(_alloc)
00033 , linear_acceleration(_alloc)
00034 , linear_acceleration_covariance()
00035 {
00036 linear_acceleration_covariance.assign(0.0);
00037 }
00038
00039 typedef ::std_msgs::Header_<ContainerAllocator> _header_type;
00040 ::std_msgs::Header_<ContainerAllocator> header;
00041
00042 typedef ::geometry_msgs::Vector3_<ContainerAllocator> _linear_acceleration_type;
00043 ::geometry_msgs::Vector3_<ContainerAllocator> linear_acceleration;
00044
00045 typedef boost::array<double, 9> _linear_acceleration_covariance_type;
00046 boost::array<double, 9> linear_acceleration_covariance;
00047
00048
00049 ROS_DEPRECATED uint32_t get_linear_acceleration_covariance_size() const { return (uint32_t)linear_acceleration_covariance.size(); }
00050 private:
00051 static const char* __s_getDataType_() { return "nxt_msgs/Accelerometer"; }
00052 public:
00053 ROS_DEPRECATED static const std::string __s_getDataType() { return __s_getDataType_(); }
00054
00055 ROS_DEPRECATED const std::string __getDataType() const { return __s_getDataType_(); }
00056
00057 private:
00058 static const char* __s_getMD5Sum_() { return "a43c5a788e7ba2f179354a76125182f0"; }
00059 public:
00060 ROS_DEPRECATED static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00061
00062 ROS_DEPRECATED const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00063
00064 private:
00065 static const char* __s_getMessageDefinition_() { return "Header header\n\
00066 geometry_msgs/Vector3 linear_acceleration\n\
00067 float64[9] linear_acceleration_covariance\n\
00068 ================================================================================\n\
00069 MSG: std_msgs/Header\n\
00070 # Standard metadata for higher-level stamped data types.\n\
00071 # This is generally used to communicate timestamped data \n\
00072 # in a particular coordinate frame.\n\
00073 # \n\
00074 # sequence ID: consecutively increasing ID \n\
00075 uint32 seq\n\
00076 #Two-integer timestamp that is expressed as:\n\
00077 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00078 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00079 # time-handling sugar is provided by the client library\n\
00080 time stamp\n\
00081 #Frame this data is associated with\n\
00082 # 0: no frame\n\
00083 # 1: global frame\n\
00084 string frame_id\n\
00085 \n\
00086 ================================================================================\n\
00087 MSG: geometry_msgs/Vector3\n\
00088 # This represents a vector in free space. \n\
00089 \n\
00090 float64 x\n\
00091 float64 y\n\
00092 float64 z\n\
00093 "; }
00094 public:
00095 ROS_DEPRECATED static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00096
00097 ROS_DEPRECATED const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00098
00099 ROS_DEPRECATED virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00100 {
00101 ros::serialization::OStream stream(write_ptr, 1000000000);
00102 ros::serialization::serialize(stream, header);
00103 ros::serialization::serialize(stream, linear_acceleration);
00104 ros::serialization::serialize(stream, linear_acceleration_covariance);
00105 return stream.getData();
00106 }
00107
00108 ROS_DEPRECATED virtual uint8_t *deserialize(uint8_t *read_ptr)
00109 {
00110 ros::serialization::IStream stream(read_ptr, 1000000000);
00111 ros::serialization::deserialize(stream, header);
00112 ros::serialization::deserialize(stream, linear_acceleration);
00113 ros::serialization::deserialize(stream, linear_acceleration_covariance);
00114 return stream.getData();
00115 }
00116
00117 ROS_DEPRECATED virtual uint32_t serializationLength() const
00118 {
00119 uint32_t size = 0;
00120 size += ros::serialization::serializationLength(header);
00121 size += ros::serialization::serializationLength(linear_acceleration);
00122 size += ros::serialization::serializationLength(linear_acceleration_covariance);
00123 return size;
00124 }
00125
00126 typedef boost::shared_ptr< ::nxt_msgs::Accelerometer_<ContainerAllocator> > Ptr;
00127 typedef boost::shared_ptr< ::nxt_msgs::Accelerometer_<ContainerAllocator> const> ConstPtr;
00128 };
00129 typedef ::nxt_msgs::Accelerometer_<std::allocator<void> > Accelerometer;
00130
00131 typedef boost::shared_ptr< ::nxt_msgs::Accelerometer> AccelerometerPtr;
00132 typedef boost::shared_ptr< ::nxt_msgs::Accelerometer const> AccelerometerConstPtr;
00133
00134
00135 template<typename ContainerAllocator>
00136 std::ostream& operator<<(std::ostream& s, const ::nxt_msgs::Accelerometer_<ContainerAllocator> & v)
00137 {
00138 ros::message_operations::Printer< ::nxt_msgs::Accelerometer_<ContainerAllocator> >::stream(s, "", v);
00139 return s;}
00140
00141 }
00142
00143 namespace ros
00144 {
00145 namespace message_traits
00146 {
00147 template<class ContainerAllocator>
00148 struct MD5Sum< ::nxt_msgs::Accelerometer_<ContainerAllocator> > {
00149 static const char* value()
00150 {
00151 return "a43c5a788e7ba2f179354a76125182f0";
00152 }
00153
00154 static const char* value(const ::nxt_msgs::Accelerometer_<ContainerAllocator> &) { return value(); }
00155 static const uint64_t static_value1 = 0xa43c5a788e7ba2f1ULL;
00156 static const uint64_t static_value2 = 0x79354a76125182f0ULL;
00157 };
00158
00159 template<class ContainerAllocator>
00160 struct DataType< ::nxt_msgs::Accelerometer_<ContainerAllocator> > {
00161 static const char* value()
00162 {
00163 return "nxt_msgs/Accelerometer";
00164 }
00165
00166 static const char* value(const ::nxt_msgs::Accelerometer_<ContainerAllocator> &) { return value(); }
00167 };
00168
00169 template<class ContainerAllocator>
00170 struct Definition< ::nxt_msgs::Accelerometer_<ContainerAllocator> > {
00171 static const char* value()
00172 {
00173 return "Header header\n\
00174 geometry_msgs/Vector3 linear_acceleration\n\
00175 float64[9] linear_acceleration_covariance\n\
00176 ================================================================================\n\
00177 MSG: std_msgs/Header\n\
00178 # Standard metadata for higher-level stamped data types.\n\
00179 # This is generally used to communicate timestamped data \n\
00180 # in a particular coordinate frame.\n\
00181 # \n\
00182 # sequence ID: consecutively increasing ID \n\
00183 uint32 seq\n\
00184 #Two-integer timestamp that is expressed as:\n\
00185 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00186 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00187 # time-handling sugar is provided by the client library\n\
00188 time stamp\n\
00189 #Frame this data is associated with\n\
00190 # 0: no frame\n\
00191 # 1: global frame\n\
00192 string frame_id\n\
00193 \n\
00194 ================================================================================\n\
00195 MSG: geometry_msgs/Vector3\n\
00196 # This represents a vector in free space. \n\
00197 \n\
00198 float64 x\n\
00199 float64 y\n\
00200 float64 z\n\
00201 ";
00202 }
00203
00204 static const char* value(const ::nxt_msgs::Accelerometer_<ContainerAllocator> &) { return value(); }
00205 };
00206
00207 template<class ContainerAllocator> struct HasHeader< ::nxt_msgs::Accelerometer_<ContainerAllocator> > : public TrueType {};
00208 template<class ContainerAllocator> struct HasHeader< const ::nxt_msgs::Accelerometer_<ContainerAllocator> > : public TrueType {};
00209 }
00210 }
00211
00212 namespace ros
00213 {
00214 namespace serialization
00215 {
00216
00217 template<class ContainerAllocator> struct Serializer< ::nxt_msgs::Accelerometer_<ContainerAllocator> >
00218 {
00219 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00220 {
00221 stream.next(m.header);
00222 stream.next(m.linear_acceleration);
00223 stream.next(m.linear_acceleration_covariance);
00224 }
00225
00226 ROS_DECLARE_ALLINONE_SERIALIZER;
00227 };
00228 }
00229 }
00230
00231 namespace ros
00232 {
00233 namespace message_operations
00234 {
00235
00236 template<class ContainerAllocator>
00237 struct Printer< ::nxt_msgs::Accelerometer_<ContainerAllocator> >
00238 {
00239 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::nxt_msgs::Accelerometer_<ContainerAllocator> & v)
00240 {
00241 s << indent << "header: ";
00242 s << std::endl;
00243 Printer< ::std_msgs::Header_<ContainerAllocator> >::stream(s, indent + " ", v.header);
00244 s << indent << "linear_acceleration: ";
00245 s << std::endl;
00246 Printer< ::geometry_msgs::Vector3_<ContainerAllocator> >::stream(s, indent + " ", v.linear_acceleration);
00247 s << indent << "linear_acceleration_covariance[]" << std::endl;
00248 for (size_t i = 0; i < v.linear_acceleration_covariance.size(); ++i)
00249 {
00250 s << indent << " linear_acceleration_covariance[" << i << "]: ";
00251 Printer<double>::stream(s, indent + " ", v.linear_acceleration_covariance[i]);
00252 }
00253 }
00254 };
00255
00256
00257 }
00258 }
00259
00260 #endif // NXT_MSGS_MESSAGE_ACCELEROMETER_H
00261