player/worlds/my_code/xswarming.cc

00001 #include <xswarming.h>
00002 
00003 int main(void)
00004 {
00005         int i=0;
00006         FILE *fp;
00007           
00012         Robot  robot1(1);
00013         Robot  robot2(2);
00014         Robot  robot3(3);
00015         
00016         fp = fopen("xswarmlogs.txt", "w");
00017         
00018         while(i < 5000)
00019         {
00020                 robot1.ReadSensors();
00022                 robot1.LogPosition(fp);
00023                 
00024                 robot2.ReadSensors();
00026                 robot2.LogPosition(fp);
00027                 
00028                 robot3.ReadSensors();
00030                 robot3.LogPosition(fp);
00031                 
00032                 i++;
00033                 usleep(250000);
00035         }
00036         fflush(fp);
00037         fclose(fp);
00038         return 0;
00039 }

Generated on Fri May 29 12:51:25 2009 for xswarm by  doxygen 1.5.5