12 #include "vda5050_msgs/State.h"
13 #include "vda5050_msgs/AGVPosition.h"
25 char buf[
sizeof "2011-10-08T07:07:09Z"];
26 strftime(buf,
sizeof buf,
"%FT%TZ", gmtime(&now));
41 vda5050_msgs::State msg;
42 msg.header.headerId=1;
44 msg.header.version=
"1.1";
45 msg.header.manufacturer=
"fml Enterprise";
46 msg.header.serialNumber=
"ajf894ajc";
47 msg.orderId=
"pass nr 3.5";
48 msg.orderUpdateId=876324;
49 msg.zoneSetId=
"fml hall of fame";
52 msg.agvPosition.theta=0;
53 msg.agvPosition.positionInitialized=
true;
54 msg.agvPosition.mapId=
"ae9748b3-8996-4a67-8709-cbbd40d95ea5";
55 msg.batteryState.batteryCharge=70.0;
62 vda5050_msgs::State
updateMessage(vda5050_msgs::State msg,
float angle,
float r,
float mx,
float my)
65 msg.agvPosition.x=r*cos(angle)+mx;
66 msg.agvPosition.y=r*sin(angle)+my;
67 msg.agvPosition.theta=angle;
71 int main(
int argc,
char **argv)
73 string topicPublish =
"state";
74 string topicViz=
"viz";
77 ros::init(argc, argv,
"state_msg_mockup");
85 cout << topicPublish <<
"\n";
92 msg.header.headerId+=1;