Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

robot/Platform

Go to the documentation of this file.
00001 /****************************************************************************
00002   Copyright (C)2002 David Jung <opensim@pobox.com>
00003 
00004   This program/file is free software; you can redistribute it and/or modify
00005   it under the terms of the GNU General Public License as published by
00006   the Free Software Foundation; either version 2 of the License, or
00007   (at your option) any later version.
00008         
00009   This program is distributed in the hope that it will be useful,
00010   but WITHOUT ANY WARRANTY; without even the implied warranty of
00011   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012   GNU General Public License for more details. (http://www.gnu.org)
00013         
00014   You should have received a copy of the GNU General Public License
00015   along with this program; if not, write to the Free Software
00016   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017 
00018   $Id: Platform,v 1.3 2002/09/14 20:59:49 jungd Exp $
00019   $Revision: 1.3 $
00020   $Date: 2002/09/14 20:59:49 $
00021   $Author: jungd $
00022  
00023 ****************************************************************************/
00024 
00025 #ifndef _ROBOT_PLATFORM_
00026 #define _ROBOT_PLATFORM_
00027 
00028 #include <robot/robot>
00029 #include <robot/RobotPart>
00030 
00031 #include <base/Dimension3>
00032 
00033 
00034 namespace robot {
00035 
00036 /**
00037  * An abstract description of a Robot's platform 
00038  *  (typically the mobile base, if any)
00039  */
00040 class Platform : public RobotPart
00041 {
00042 public:
00043   virtual bool   isMobile() const    ///< is the robot mobile, or fixed (e.g. to the floor)?
00044     { return mobile; }
00045   virtual bool   isHolonomic() const ///< if mobile, is the platform capable of holonomic movement
00046     { return holonomic; }
00047 
00048   virtual base::Dimension3 getDimensions() const ///< physical platform bounding dimensions (Length, Width, Thickness)
00049     { return dimensions; }
00050   
00051 protected:
00052   Platform() 
00053     : mobile(false) {}
00054   Platform(String name) : RobotPart(name), mobile(false) {}
00055   Platform(const Platform& p)
00056     : RobotPart(p),
00057       mobile(p.mobile), holonomic(p.holonomic), dimensions(p.dimensions) {}
00058 
00059   bool   mobile;    
00060   bool   holonomic; 
00061   
00062   base::Dimension3 dimensions; 
00063 };
00064 
00065 
00066 } // robot
00067 
00068 #endif

Generated on Thu Nov 21 23:58:04 2002 for OpenSim by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002