ric_calib.h
Go to the documentation of this file.
00001 #ifndef _ROS_SERVICE_ric_calib_h
00002 #define _ROS_SERVICE_ric_calib_h
00003 #include <stdint.h>
00004 #include <string.h>
00005 #include <stdlib.h>
00006 #include "ros/msg.h"
00007 
00008 namespace ric_robot
00009 {
00010 
00011 static const char RIC_CALIB[] = "ric_robot/ric_calib";
00012 
00013   class ric_calibRequest : public ros::Msg
00014   {
00015     public:
00016       int16_t com;
00017 
00018     virtual int serialize(unsigned char *outbuffer) const
00019     {
00020       int offset = 0;
00021       union {
00022         int16_t real;
00023         uint16_t base;
00024       } u_com;
00025       u_com.real = this->com;
00026       *(outbuffer + offset + 0) = (u_com.base >> (8 * 0)) & 0xFF;
00027       *(outbuffer + offset + 1) = (u_com.base >> (8 * 1)) & 0xFF;
00028       offset += sizeof(this->com);
00029       return offset;
00030     }
00031 
00032     virtual int deserialize(unsigned char *inbuffer)
00033     {
00034       int offset = 0;
00035       union {
00036         int16_t real;
00037         uint16_t base;
00038       } u_com;
00039       u_com.base = 0;
00040       u_com.base |= ((uint16_t) (*(inbuffer + offset + 0))) << (8 * 0);
00041       u_com.base |= ((uint16_t) (*(inbuffer + offset + 1))) << (8 * 1);
00042       this->com = u_com.real;
00043       offset += sizeof(this->com);
00044      return offset;
00045     }
00046 
00047     const char * getType(){ return RIC_CALIB; };
00048     const char * getMD5(){ return "0dce049a176069675a0c664de0822e2c"; };
00049 
00050   };
00051 
00052   class ric_calibResponse : public ros::Msg
00053   {
00054     public:
00055       bool ack;
00056 
00057     virtual int serialize(unsigned char *outbuffer) const
00058     {
00059       int offset = 0;
00060       union {
00061         bool real;
00062         uint8_t base;
00063       } u_ack;
00064       u_ack.real = this->ack;
00065       *(outbuffer + offset + 0) = (u_ack.base >> (8 * 0)) & 0xFF;
00066       offset += sizeof(this->ack);
00067       return offset;
00068     }
00069 
00070     virtual int deserialize(unsigned char *inbuffer)
00071     {
00072       int offset = 0;
00073       union {
00074         bool real;
00075         uint8_t base;
00076       } u_ack;
00077       u_ack.base = 0;
00078       u_ack.base |= ((uint8_t) (*(inbuffer + offset + 0))) << (8 * 0);
00079       this->ack = u_ack.real;
00080       offset += sizeof(this->ack);
00081      return offset;
00082     }
00083 
00084     const char * getType(){ return RIC_CALIB; };
00085     const char * getMD5(){ return "8f5729177853f34b146e2e57766d4dc2"; };
00086 
00087   };
00088 
00089   class ric_calib {
00090     public:
00091     typedef ric_calibRequest Request;
00092     typedef ric_calibResponse Response;
00093   };
00094 
00095 }
00096 #endif


ric_mc
Author(s): RoboTiCan
autogenerated on Fri May 20 2016 03:48:56