33 #include <PanTilt/DPPanTiltControl.hh>
38 int main(
int argc,
char *argv[])
48 cout<<
"Initialising PTU failed!"<<endl;
52 panTiltControl.
SetMode(ABSOLUTEMODE);
55 panTiltControl.
SetSpeed(DPPTU_MAXSPEED/4, DPPTU_MAXSPEED/4);
61 panTiltControl.
SetMode(SPEEDMODE);
void AwaitCompletion()
Await completion of currently executed command.
char SetSpeed(int nPanSpeed, int nTiltSpeed)
Set speed for movement.
Basic controller interface for Directed Perception Pan Tilt Unit.
void SetPosition(int nPanPos, int nTiltPos, bool bWaitComplete=true)
Set the current position of the PTU in steps.
int SetMode(int nMode)
Set the mode in which the camera is to operate.
void ClosePanTiltUnit()
closes the comport stream connected to PTU
bool InitPanTiltUnit(int nPort, bool bUSB=false)
Open the given serial port and initialize the pan tilt unit.