/* program to move robot forward, backward, left, and right a few times
   robot beeps after each movement
 */

#include <stdio.h>
#include <MyroC.h>

int main () {

   printf ("connecting to robot\n");
   rConnect ("B4:D8:A9:00:09:50");

   rBeep (0.5, 850);
   printf ("moving forward\n");
   rForward (0.5, 0.5);

   rBeep (0.5, 900);
   printf ("turning right\n");
   rTurnRight (0.5, 0.5);

   rBeep (0.5, 950);
   printf ("moving backward\n");
   rBackward (0.5, 0.5);
   
   rBeep (0.5, 1000);
   printf ("turning left\n");
   rTurnLeft (0.5, 0.5);
   
   rBeep (0.5, 1050);
   printf ("program completed\n");

   return 0;
}