Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | Related Pages | Examples

ArActionGroups.h

00001 /*
00002 MobileRobots Advanced Robotics Interface for Applications (ARIA)
00003 Copyright (C) 2004, 2005 ActivMedia Robotics LLC
00004 Copyright (C) 2006, 2007 MobileRobots Inc.
00005 
00006      This program is free software; you can redistribute it and/or modify
00007      it under the terms of the GNU General Public License as published by
00008      the Free Software Foundation; either version 2 of the License, or
00009      (at your option) any later version.
00010 
00011      This program is distributed in the hope that it will be useful,
00012      but WITHOUT ANY WARRANTY; without even the implied warranty of
00013      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014      GNU General Public License for more details.
00015 
00016      You should have received a copy of the GNU General Public License
00017      along with this program; if not, write to the Free Software
00018      Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00019 
00020 If you wish to redistribute ARIA under different terms, contact 
00021 MobileRobots for information about a commercial version of ARIA at 
00022 robots@mobilerobots.com or 
00023 MobileRobots Inc, 19 Columbia Drive, Amherst, NH 03031; 800-639-9481
00024 */
00025 
00026 #ifndef ARACTIONGROUPS_H
00027 #define ARACTIONGROUPS_H
00028 
00029 #include "ariaTypedefs.h"
00030 #include "ArActionGroup.h"
00031 #include "ArActionColorFollow.h"
00032 #include "ArACTS.h"
00033 #include "ArPTZ.h"
00034 
00035 class ArActionInput;
00036 class ArActionJoydrive;
00037 class ArActionDeceleratingLimiter;
00038 class ArActionRatioInput;
00039 class ArRatioInputKeydrive;
00040 class ArRatioInputJoydrive;
00041 class ArRatioInputRobotJoydrive;
00042 
00044 
00056 class ArActionGroupInput : public ArActionGroup
00057 {
00058 public:
00059   AREXPORT ArActionGroupInput(ArRobot *robot);
00060   AREXPORT virtual ~ArActionGroupInput();
00061   AREXPORT void setVel(double vel);
00062   AREXPORT void setRotVel(double rotVel);
00063   AREXPORT void setHeading(double heading);
00064   AREXPORT void deltaHeadingFromCurrent(double delta);
00065   AREXPORT void clear(void);
00066   AREXPORT ArActionInput *getActionInput(void);
00067 protected:
00068   ArActionInput *myInput;
00069 };
00070 
00072 
00077 class ArActionGroupStop : public ArActionGroup
00078 {
00079 public:
00080   AREXPORT ArActionGroupStop(ArRobot *robot);
00081   AREXPORT virtual ~ArActionGroupStop();
00082 };
00083 
00085 
00091 class ArActionGroupTeleop : public ArActionGroup
00092 {
00093 public:
00094   AREXPORT ArActionGroupTeleop(ArRobot *robot);
00095   AREXPORT virtual ~ArActionGroupTeleop();
00096   AREXPORT void setThrottleParams(int lowSpeed, int highSpeed);
00097 protected:
00098   ArActionJoydrive *myJoydrive;
00099 };
00100 
00102 
00108 class ArActionGroupUnguardedTeleop : public ArActionGroup
00109 {
00110 public:
00111   AREXPORT ArActionGroupUnguardedTeleop(ArRobot *robot);
00112   AREXPORT virtual ~ArActionGroupUnguardedTeleop();
00113   AREXPORT void setThrottleParams(int lowSpeed, int highSpeed);
00114 protected:
00115   ArActionJoydrive *myJoydrive;
00116 };
00117 
00119 
00124 class ArActionGroupWander : public ArActionGroup
00125 {
00126 public:
00127   AREXPORT ArActionGroupWander(ArRobot *robot, int forwardVel = 400, int avoidFrontDist = 450, int avoidVel = 200, int avoidTurnAmt = 15);
00128   AREXPORT virtual ~ArActionGroupWander();
00129 };
00130 
00132 
00138 class ArActionGroupColorFollow : public ArActionGroup
00139 {
00140 public:
00141   AREXPORT ArActionGroupColorFollow(ArRobot *robot, ArACTS_1_2 *acts, ArPTZ *camera);
00142   AREXPORT virtual ~ArActionGroupColorFollow();
00143   AREXPORT void setCamera(ArPTZ *camera);
00144   AREXPORT void setChannel(int channel);
00145   AREXPORT void startMovement();
00146   AREXPORT void stopMovement();
00147   AREXPORT void setAcquire(bool acquire);
00148   AREXPORT int getChannel();
00149   AREXPORT bool getAcquire();
00150   AREXPORT bool getMovement();
00151   AREXPORT bool getBlob();
00152 protected:
00153   ArActionColorFollow *myColorFollow;
00154 };
00155 
00157 
00163 class ArActionGroupRatioDrive : public ArActionGroup
00164 {
00165 public:
00166   AREXPORT ArActionGroupRatioDrive(ArRobot *robot);
00167   AREXPORT virtual ~ArActionGroupRatioDrive();
00168   AREXPORT ArActionRatioInput *getActionRatioInput(void);
00169   AREXPORT void addToConfig(ArConfig *config, const char *section);
00170 protected:
00171   ArActionDeceleratingLimiter *myDeceleratingLimiterForward;
00172   ArActionDeceleratingLimiter *myDeceleratingLimiterBackward;
00173   ArActionRatioInput *myInput;
00174   ArRatioInputKeydrive *myKeydrive;
00175   ArRatioInputJoydrive *myJoydrive;
00176   ArRatioInputRobotJoydrive *myRobotJoydrive;
00177 
00178 };
00179 
00180 
00182 
00188 class ArActionGroupRatioDriveUnsafe : public ArActionGroup
00189 {
00190 public:
00191   AREXPORT ArActionGroupRatioDriveUnsafe(ArRobot *robot);
00192   AREXPORT virtual ~ArActionGroupRatioDriveUnsafe();
00193   AREXPORT ArActionRatioInput *getActionRatioInput(void);
00194   AREXPORT void addToConfig(ArConfig *config, const char *section);
00195 protected:
00196   ArActionRatioInput *myInput;
00197   ArRatioInputKeydrive *myKeydrive;
00198   ArRatioInputJoydrive *myJoydrive;
00199   ArRatioInputRobotJoydrive *myRobotJoydrive;
00200 
00201 };
00202 
00203 #endif // ARACTIONGROUPS_H

Generated on Tue Feb 20 10:51:38 2007 for Aria by  doxygen 1.4.0