nav2remote.h
Go to the documentation of this file.
00001 /*
00002   Copyright (C) 2012 CrossWing Inc. www.crosswing.com
00003   All Rights Reserved.
00004 */
00005 
00006 #ifndef _NAV2REMOTE_H_
00007 #define _NAV2REMOTE_H_
00008 
00027 class Nav2Remote
00028 {
00029     // No copying allowed
00030     Nav2Remote(const Nav2Remote&);
00031     Nav2Remote& operator=(const Nav2Remote&);
00032 
00033     mutable char *line;
00034     mutable int lineLen;
00035     int fd;
00036 
00037     int readLine() const;
00038 
00039 public:
00050     Nav2Remote( const char* host, int port=5010);
00051 
00052     ~Nav2Remote();
00053 
00065     int setTargetOrientation( double orientation);
00066 
00078     int setAbsoluteVelocity( double vx, double vy);
00079 
00104     int setRelativeVelocity( double vx, double vy, double turnRate=0.0);
00105 
00116     int estimatePosition( double& x, double& y, double& orientation) const;
00117 
00129     int setPosition( double x, double y, double orientation);
00130 
00136     int stop();
00137 
00146     int turnLeft( double angle);
00147 
00156     int turnRight( double angle) { return turnLeft( -angle); }
00157 
00170     int move( double dist, double direction);
00171 
00181     int forward( double dist) { return move(dist,0.0); }
00182 
00192     int back( double dist) { return forward(-dist); }
00193 
00203     int setMaxSpeed( double maxSpeed);
00204 
00214     int setMaxAccel( double maxAccel);
00215 
00229     int setMaxCorneringError( double error);
00230 
00237     double getMaxSpeed() const;
00238 
00246     double getMaxAccel() const;
00247 
00254     double getMaxCorneringError() const;
00255 
00263     int getQueueSize() const;
00264 
00270     int wait() const;
00271 };
00272 
00273 #endif


nav2_driver
Author(s): Paul Bovbel
autogenerated on Fri Aug 28 2015 11:45:16