/* LICENSE:
  =========================================================================
    CMPack'04 Source Code Release for OPEN-R SDK 1.1.5-r2 for ERS7
    Copyright (C) 2004 Multirobot Lab [Project Head: Manuela Veloso]
    School of Computer Science, Carnegie Mellon University
    All rights reserved.
  ========================================================================= */

#ifndef PupPilotMsg_h
#define PupPilotMsg_h

#include "../headers/Util.h"
#include "../Motion/MotionInterface.h"

/* I'm tempted to just send a raw motion command to the robot,
   but it's a pain to include dog headers in Linux - we have
   some incompatable typedefs and you always end up including
   more than you want.
*/

struct PupPilotMsg {
  unsigned long header;
  
  Motion::MotionCommand cmd;

  uchar pause;

  void reset()
  {
    header = 0xC0EDBEEFUL;
    mzero(cmd);
    cmd.head_lookat.set(1000.0,0.0,0.0);
  }
  
  PupPilotMsg() {
    pause = false;
    reset();
  }
} __attribute__ ((aligned(8)));

#endif
