00001
00002 #ifndef ASCTEC_MSGS_MESSAGE_RCDATA_H
00003 #define ASCTEC_MSGS_MESSAGE_RCDATA_H
00004 #include <string>
00005 #include <vector>
00006 #include <map>
00007 #include <ostream>
00008 #include "ros/serialization.h"
00009 #include "ros/builtin_message_traits.h"
00010 #include "ros/message_operations.h"
00011 #include "ros/time.h"
00012
00013 #include "ros/macros.h"
00014
00015 #include "ros/assert.h"
00016
00017 #include "std_msgs/Header.h"
00018
00019 namespace asctec_msgs
00020 {
00021 template <class ContainerAllocator>
00022 struct RCData_ {
00023 typedef RCData_<ContainerAllocator> Type;
00024
00025 RCData_()
00026 : header()
00027 , channels_in()
00028 , channels_out()
00029 , lock(0)
00030 {
00031 channels_in.assign(0);
00032 channels_out.assign(0);
00033 }
00034
00035 RCData_(const ContainerAllocator& _alloc)
00036 : header(_alloc)
00037 , channels_in()
00038 , channels_out()
00039 , lock(0)
00040 {
00041 channels_in.assign(0);
00042 channels_out.assign(0);
00043 }
00044
00045 typedef ::std_msgs::Header_<ContainerAllocator> _header_type;
00046 ::std_msgs::Header_<ContainerAllocator> header;
00047
00048 typedef boost::array<int16_t, 8> _channels_in_type;
00049 boost::array<int16_t, 8> channels_in;
00050
00051 typedef boost::array<int16_t, 8> _channels_out_type;
00052 boost::array<int16_t, 8> channels_out;
00053
00054 typedef int16_t _lock_type;
00055 int16_t lock;
00056
00057
00058 typedef boost::shared_ptr< ::asctec_msgs::RCData_<ContainerAllocator> > Ptr;
00059 typedef boost::shared_ptr< ::asctec_msgs::RCData_<ContainerAllocator> const> ConstPtr;
00060 boost::shared_ptr<std::map<std::string, std::string> > __connection_header;
00061 };
00062 typedef ::asctec_msgs::RCData_<std::allocator<void> > RCData;
00063
00064 typedef boost::shared_ptr< ::asctec_msgs::RCData> RCDataPtr;
00065 typedef boost::shared_ptr< ::asctec_msgs::RCData const> RCDataConstPtr;
00066
00067
00068 template<typename ContainerAllocator>
00069 std::ostream& operator<<(std::ostream& s, const ::asctec_msgs::RCData_<ContainerAllocator> & v)
00070 {
00071 ros::message_operations::Printer< ::asctec_msgs::RCData_<ContainerAllocator> >::stream(s, "", v);
00072 return s;}
00073
00074 }
00075
00076 namespace ros
00077 {
00078 namespace message_traits
00079 {
00080 template<class ContainerAllocator> struct IsMessage< ::asctec_msgs::RCData_<ContainerAllocator> > : public TrueType {};
00081 template<class ContainerAllocator> struct IsMessage< ::asctec_msgs::RCData_<ContainerAllocator> const> : public TrueType {};
00082 template<class ContainerAllocator>
00083 struct MD5Sum< ::asctec_msgs::RCData_<ContainerAllocator> > {
00084 static const char* value()
00085 {
00086 return "d486363e6033911606202acafb1bc1a0";
00087 }
00088
00089 static const char* value(const ::asctec_msgs::RCData_<ContainerAllocator> &) { return value(); }
00090 static const uint64_t static_value1 = 0xd486363e60339116ULL;
00091 static const uint64_t static_value2 = 0x06202acafb1bc1a0ULL;
00092 };
00093
00094 template<class ContainerAllocator>
00095 struct DataType< ::asctec_msgs::RCData_<ContainerAllocator> > {
00096 static const char* value()
00097 {
00098 return "asctec_msgs/RCData";
00099 }
00100
00101 static const char* value(const ::asctec_msgs::RCData_<ContainerAllocator> &) { return value(); }
00102 };
00103
00104 template<class ContainerAllocator>
00105 struct Definition< ::asctec_msgs::RCData_<ContainerAllocator> > {
00106 static const char* value()
00107 {
00108 return "# Software License Agreement (BSD License)\n\
00109 #\n\
00110 # Copyright (c) 2010\n\
00111 # William Morris <morris@ee.ccny.cuny.edu>\n\
00112 # Ivan Dryanovski <ivan.dryanovski@gmail.com>\n\
00113 # All rights reserved.\n\
00114 #\n\
00115 # Redistribution and use in source and binary forms, with or without\n\
00116 # modification, are permitted provided that the following conditions\n\
00117 # are met:\n\
00118 #\n\
00119 # * Redistributions of source code must retain the above copyright\n\
00120 # notice, this list of conditions and the following disclaimer.\n\
00121 # * Redistributions in binary form must reproduce the above\n\
00122 # copyright notice, this list of conditions and the following\n\
00123 # disclaimer in the documentation and/or other materials provided\n\
00124 # with the distribution.\n\
00125 # * Neither the name of CCNY Robotics Lab nor the names of its\n\
00126 # contributors may be used to endorse or promote products derived\n\
00127 # from this software without specific prior written permission.\n\
00128 #\n\
00129 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n\
00130 # \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n\
00131 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS\n\
00132 # FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE\n\
00133 # COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,\n\
00134 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,\n\
00135 # BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\n\
00136 # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\n\
00137 # CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT\n\
00138 # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN\n\
00139 # ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE\n\
00140 # POSSIBILITY OF SUCH DAMAGE.\n\
00141 \n\
00142 # struct RC_DATA\n\
00143 # {\n\
00144 # //channels as read from R/C receiver\n\
00145 # unsigned short channels_in[8];\n\
00146 # //channels bias free, remapped and scaled to 0..4095\n\
00147 # unsigned short channels_out[8];\n\
00148 # //Indicator for valid R/C receiption\n\
00149 # unsigned char lock;\n\
00150 # };\n\
00151 Header header\n\
00152 # channels as read from R/C receiver\n\
00153 int16[8] channels_in\n\
00154 \n\
00155 #channels bias free, remapped and scaled to 0..4095\n\
00156 int16[8] channels_out\n\
00157 \n\
00158 #indicator for valid R/C receiption\n\
00159 int16 lock\n\
00160 \n\
00161 ================================================================================\n\
00162 MSG: std_msgs/Header\n\
00163 # Standard metadata for higher-level stamped data types.\n\
00164 # This is generally used to communicate timestamped data \n\
00165 # in a particular coordinate frame.\n\
00166 # \n\
00167 # sequence ID: consecutively increasing ID \n\
00168 uint32 seq\n\
00169 #Two-integer timestamp that is expressed as:\n\
00170 # * stamp.secs: seconds (stamp_secs) since epoch\n\
00171 # * stamp.nsecs: nanoseconds since stamp_secs\n\
00172 # time-handling sugar is provided by the client library\n\
00173 time stamp\n\
00174 #Frame this data is associated with\n\
00175 # 0: no frame\n\
00176 # 1: global frame\n\
00177 string frame_id\n\
00178 \n\
00179 ";
00180 }
00181
00182 static const char* value(const ::asctec_msgs::RCData_<ContainerAllocator> &) { return value(); }
00183 };
00184
00185 template<class ContainerAllocator> struct HasHeader< ::asctec_msgs::RCData_<ContainerAllocator> > : public TrueType {};
00186 template<class ContainerAllocator> struct HasHeader< const ::asctec_msgs::RCData_<ContainerAllocator> > : public TrueType {};
00187 }
00188 }
00189
00190 namespace ros
00191 {
00192 namespace serialization
00193 {
00194
00195 template<class ContainerAllocator> struct Serializer< ::asctec_msgs::RCData_<ContainerAllocator> >
00196 {
00197 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00198 {
00199 stream.next(m.header);
00200 stream.next(m.channels_in);
00201 stream.next(m.channels_out);
00202 stream.next(m.lock);
00203 }
00204
00205 ROS_DECLARE_ALLINONE_SERIALIZER;
00206 };
00207 }
00208 }
00209
00210 namespace ros
00211 {
00212 namespace message_operations
00213 {
00214
00215 template<class ContainerAllocator>
00216 struct Printer< ::asctec_msgs::RCData_<ContainerAllocator> >
00217 {
00218 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::asctec_msgs::RCData_<ContainerAllocator> & v)
00219 {
00220 s << indent << "header: ";
00221 s << std::endl;
00222 Printer< ::std_msgs::Header_<ContainerAllocator> >::stream(s, indent + " ", v.header);
00223 s << indent << "channels_in[]" << std::endl;
00224 for (size_t i = 0; i < v.channels_in.size(); ++i)
00225 {
00226 s << indent << " channels_in[" << i << "]: ";
00227 Printer<int16_t>::stream(s, indent + " ", v.channels_in[i]);
00228 }
00229 s << indent << "channels_out[]" << std::endl;
00230 for (size_t i = 0; i < v.channels_out.size(); ++i)
00231 {
00232 s << indent << " channels_out[" << i << "]: ";
00233 Printer<int16_t>::stream(s, indent + " ", v.channels_out[i]);
00234 }
00235 s << indent << "lock: ";
00236 Printer<int16_t>::stream(s, indent + " ", v.lock);
00237 }
00238 };
00239
00240
00241 }
00242 }
00243
00244 #endif // ASCTEC_MSGS_MESSAGE_RCDATA_H
00245