/*!
  \file
  \brief 直線追従の動作サンプル

  \author Satofumi KAMIMURA

  $Id: followLine.cpp 1525 2009-11-16 17:52:07Z satofumi $
*/

#include "BeegoDrive.h"
#include "delay.h"
#include <cstdlib>

using namespace qrk;
using namespace std;


int main(int argc, char *argv[])
{
  const char device[] = "/dev/usb/ttyUSB0";

  BeegoDrive run;
  if (! run.connect(device)) {
    cout << "BeegoDrive::connect(): " << run.what() << endl;
    exit(1);
  }

  //run.followLine(Position<long>(0, 0, deg(0)));
  run.followLine(0, 0, deg(0));
  delay(2000);

  run.stop();

  return 0;
}
