#ifndef PROVACM_H_DEFINED
#define PROVACM_H_DEFINED
#include <OPENR/OObject.h>
#include <OPENR/OSubject.h>
#include <OPENR/OObserver.h>
#include <OPENR/RCRegion.h>
#include "def.h"
#include <queue>
#include "../headers/Geometry.h"
#include "../Motion/MotionInterface.h"

using namespace std;

class ProvaCM : public OObject {
public:
  ProvaCM();
  virtual ~ProvaCM() {};

  OSubject*    subject[numOfSubject];
  OObserver*   observer[numOfObserver];
   
  virtual OStatus DoInit   (const OSystemEvent& event);
  virtual OStatus DoStart  (const OSystemEvent& event);
  virtual OStatus DoStop   (const OSystemEvent& event);
  virtual OStatus DoDestroy(const OSystemEvent& event);
  void Notify(const ONotifyEvent& event);
  void Ready(const OReadyEvent& event);

  void TimerEnd(void* msg);
private:
  queue<Motion::MotionCommand> codaComandi;
};

#endif
