This program is porting rosserial_arduino for mbed http://www.ros.org/wiki/rosserial_arduino This program supported the revision of 169 of rosserial. This program contains an example.

Dependencies:   rosserial_mbed_lib mbed Servo

Committer:
nucho
Date:
Sat Nov 12 23:53:04 2011 +0000
Revision:
3:dff241b66f84
This program supported the revision of 167 of rosserial.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
nucho 3:dff241b66f84 1 #ifndef _ROS_SERVICE_Empty_h
nucho 3:dff241b66f84 2 #define _ROS_SERVICE_Empty_h
nucho 3:dff241b66f84 3 #include <stdint.h>
nucho 3:dff241b66f84 4 #include <string.h>
nucho 3:dff241b66f84 5 #include <stdlib.h>
nucho 3:dff241b66f84 6 #include "ros/msg.h"
nucho 3:dff241b66f84 7
nucho 3:dff241b66f84 8 namespace roscpp
nucho 3:dff241b66f84 9 {
nucho 3:dff241b66f84 10
nucho 3:dff241b66f84 11 static const char EMPTY[] = "roscpp/Empty";
nucho 3:dff241b66f84 12
nucho 3:dff241b66f84 13 class EmptyRequest : public ros::Msg
nucho 3:dff241b66f84 14 {
nucho 3:dff241b66f84 15 public:
nucho 3:dff241b66f84 16
nucho 3:dff241b66f84 17 virtual int serialize(unsigned char *outbuffer) const
nucho 3:dff241b66f84 18 {
nucho 3:dff241b66f84 19 int offset = 0;
nucho 3:dff241b66f84 20 return offset;
nucho 3:dff241b66f84 21 }
nucho 3:dff241b66f84 22
nucho 3:dff241b66f84 23 virtual int deserialize(unsigned char *inbuffer)
nucho 3:dff241b66f84 24 {
nucho 3:dff241b66f84 25 int offset = 0;
nucho 3:dff241b66f84 26 return offset;
nucho 3:dff241b66f84 27 }
nucho 3:dff241b66f84 28
nucho 3:dff241b66f84 29 virtual const char * getType(){ return EMPTY; };
nucho 3:dff241b66f84 30 virtual const char * getMD5(){ return "d41d8cd98f00b204e9800998ecf8427e"; };
nucho 3:dff241b66f84 31
nucho 3:dff241b66f84 32 };
nucho 3:dff241b66f84 33
nucho 3:dff241b66f84 34 class EmptyResponse : public ros::Msg
nucho 3:dff241b66f84 35 {
nucho 3:dff241b66f84 36 public:
nucho 3:dff241b66f84 37
nucho 3:dff241b66f84 38 virtual int serialize(unsigned char *outbuffer) const
nucho 3:dff241b66f84 39 {
nucho 3:dff241b66f84 40 int offset = 0;
nucho 3:dff241b66f84 41 return offset;
nucho 3:dff241b66f84 42 }
nucho 3:dff241b66f84 43
nucho 3:dff241b66f84 44 virtual int deserialize(unsigned char *inbuffer)
nucho 3:dff241b66f84 45 {
nucho 3:dff241b66f84 46 int offset = 0;
nucho 3:dff241b66f84 47 return offset;
nucho 3:dff241b66f84 48 }
nucho 3:dff241b66f84 49
nucho 3:dff241b66f84 50 virtual const char * getType(){ return EMPTY; };
nucho 3:dff241b66f84 51 virtual const char * getMD5(){ return "d41d8cd98f00b204e9800998ecf8427e"; };
nucho 3:dff241b66f84 52
nucho 3:dff241b66f84 53 };
nucho 3:dff241b66f84 54
nucho 3:dff241b66f84 55 class Empty {
nucho 3:dff241b66f84 56 public:
nucho 3:dff241b66f84 57 typedef EmptyRequest Request;
nucho 3:dff241b66f84 58 typedef EmptyResponse Response;
nucho 3:dff241b66f84 59 };
nucho 3:dff241b66f84 60
nucho 3:dff241b66f84 61 }
nucho 3:dff241b66f84 62 #endif