Tekkotsu Homepage | Demos | Overview | Downloads | Dev. Resources | Reference | Credits |
RobotInfo::Capabilities Class ReferenceAllows behaviors to lookup output/button/sensor names from other models to support basic cross-model portability. More...
Inheritance diagram for RobotInfo::Capabilities:
Detailed DescriptionAllows behaviors to lookup output/button/sensor names from other models to support basic cross-model portability. Use the getCapabilities() function to look up the Capabalities instance for a given model based on its string robot name Definition at line 101 of file CommonInfo.h.
Constructor & Destructor Documentation
constructor, pass the robot name this is regarding, and outputs, buttons, and sensor names Definition at line 248 of file RobotInfo.cc.
shallow copy (explicit to satisfy warning) Definition at line 107 of file CommonInfo.h.
destructor, explicit just to avoid warning when used as base class Definition at line 123 of file CommonInfo.h. Member Function Documentation
look up the offset corresponding to a button name, returns -1U if not found/available Identical to getButtonOffset(), except returns an invalid value instead of throwing an exception. Use this if you are testing to see if a capability exists, and don't want to incur exception handling if it isn't (say you're doing a lot of testing) Definition at line 189 of file CommonInfo.h. Referenced by TorqueCalibrate::TakeMeasurementControl::activate(), CameraBehavior::doStart(), PostureEngine::loadLine(), and Controller::takeLine().
look up the offset corresponding to a reference frame name, returns -1U if not found/available Identical to getFrameOffset(), except returns an invalid value instead of throwing an exception. Use this if you are testing to see if a capability exists, and don't want to incur exception handling if it isn't (say you're doing a lot of testing) Definition at line 185 of file CommonInfo.h. Referenced by plist::OutputSelector::get(), plist::OutputSelector::loadXML(), ArmMC::moveOffsetToPoint(), ArmMC::moveOffsetToPointWithOrientation(), plist::OutputSelector::set(), Grasper::CloseTheGripper::setup(), and Grasper::OpenTheGripper::setup().
look up the offset corresponding to a output name, returns -1U if not found/available Identical to getOutputOffset(), except returns an invalid value instead of throwing an exception. Use this if you are testing to see if a capability exists, and don't want to incur exception handling if it isn't (say you're doing a lot of testing) Definition at line 178 of file CommonInfo.h. Referenced by PostureMC::defaultMaxSpeed(), HeadPointerMC::defaultMaxSpeed(), PostureEngine::loadLine(), HeadController::runCommand(), RunSequenceControl< SequenceSize >::selectedFile(), LoadPostureControl::selectedFile(), HeadPointerMC::setJoints(), and XWalkMC::updateOutputsWalking().
look up the offset corresponding to a sensor name, returns -1U if not found/available Identical to getSensorOffset(), except returns an invalid value instead of throwing an exception. Use this if you are testing to see if a capability exists, and don't want to incur exception handling if it isn't (say you're doing a lot of testing) Definition at line 193 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
look up the name corresponding to an offset, returns NULL if not found/available Definition at line 147 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
look up the offset corresponding to a button name, throws std::invalid_argument if not found Identical to findButtonOffset(), except throws an exception instead of returning an invalid value. Use this if you expect that the button is available, and want a noisy fail-fast if something's wrong (e.g. typo in name?) Definition at line 169 of file CommonInfo.h. Referenced by CameraBehavior::doStart(), and EmergencyStopMC::trigger().
returns a static map from robot names to capability instances, which are externally allocated The Capabilties base class will automatically insert entries into this collection. Definition at line 272 of file RobotInfo.cc. Referenced by Capabilities(), and RobotInfo::getCapabilities().
returns the offsets of "fake" outputs, see fakeOutputs Definition at line 196 of file CommonInfo.h.
look up the name corresponding to an offset, returns NULL if not found/available Definition at line 145 of file CommonInfo.h. Referenced by plist::OutputSelector::get(), plist::OutputSelector::loadXML(), plist::OutputSelector::operator=(), plist::OutputSelector::set(), and plist::OutputSelector::setRange().
Look up the offset corresponding to a reference frame name, throws std::invalid_argument if not found. Identical to findFrameOffset(), except throws an exception instead of returning an invalid value. Use this if you expect that the frame is available, and want a noisy fail-fast if something's wrong (e.g. typo in name?) Definition at line 165 of file CommonInfo.h.
returns the offset of the block of LEDs in an output array Definition at line 139 of file CommonInfo.h.
returns the number of unique buttons (i.e. not counting aliases) Definition at line 133 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
returns the number of unique reference frames (includes all outputs, plus unactuated points of interest, like cameras or end effector tips Definition at line 131 of file CommonInfo.h. Referenced by plist::OutputSelector::loadXML(), plist::OutputSelector::operator=(), plist::OutputSelector::set(), and plist::OutputSelector::setRange().
returns the number of LEDs Definition at line 140 of file CommonInfo.h.
returns the number of unique outputs (i.e. not counting aliases and non-actuated reference frames) Definition at line 129 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
returns the number of 'PID' joints Definition at line 138 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
returns the number of unique sensors (i.e. not counting aliases) Definition at line 135 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
look up the name corresponding to an offset, returns NULL if not found/available Definition at line 143 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
Look up the offset corresponding to a output name, throws std::invalid_argument if not found. Identical to findOutputOffset(), except throws an exception instead of returning an invalid value. Use this if you expect that the output is available, and want a noisy fail-fast if something's wrong (e.g. typo in name?) Definition at line 154 of file CommonInfo.h. Referenced by EmergencyStopMC::EmergencyStopMC(), EmergencyStopMC::freezeJoints(), BatteryMonitorBehavior::setFlipper(), and TailWagMC::updateOutputs().
returns the offset of the block of 'PID' joints in an output array Definition at line 137 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
returns the name of the robot this corresponds to Definition at line 126 of file CommonInfo.h. Referenced by plist::OutputSelector::get(), PostureEngine::loadLine(), plist::OutputSelector::loadXML(), plist::OutputSelector::operator=(), and plist::OutputSelector::set().
look up the name corresponding to an offset, returns NULL if not found/available Definition at line 149 of file CommonInfo.h. Referenced by PostureEngine::loadLine().
look up the offset corresponding to a sensor name, throws std::invalid_argument if not found Identical to findSensorOffset(), except throws an exception instead of returning an invalid value. Use this if you expect that the sensor is available, and want a noisy fail-fast if something's wrong (e.g. typo in name?) Definition at line 173 of file CommonInfo.h.
helper function, does the work of the find..Offset functions Definition at line 209 of file CommonInfo.h. Referenced by DynamicInfo::DynamicCapabilities::findButtonOffset(), findButtonOffset(), DynamicInfo::DynamicCapabilities::findFrameOffset(), findFrameOffset(), DynamicInfo::DynamicCapabilities::findOutputOffset(), findOutputOffset(), DynamicInfo::DynamicCapabilities::findSensorOffset(), and findSensorOffset().
helper function, does the work of the get..Offset functions Definition at line 200 of file CommonInfo.h. Referenced by DynamicInfo::DynamicCapabilities::getButtonOffset(), getButtonOffset(), DynamicInfo::DynamicCapabilities::getFrameOffset(), getFrameOffset(), DynamicInfo::DynamicCapabilities::getOutputOffset(), getOutputOffset(), DynamicInfo::DynamicCapabilities::getSensorOffset(), and getSensorOffset().
shallow assign (explicit to satisfy warning) Definition at line 114 of file CommonInfo.h. Friends And Related Function Documentation
Accessor for Capabilities::caps, returns the Capabilities instance for a specified robot model (or NULL if robot is unknown or didn't provide a Capabilities instance). Use this if you have a robot name in string form and want to check or map its capabilities. (For example, if you are communicating with another robot of a different type over the network.) If you know at compile time the type of the robot in question, you could just directly access its 'capabilities' instance via its RobotInfo namespace. (e.g. ERS210Info::capabilities) If you want the capabilities for the current robot, just use the global 'capabilities' instance as RobotInfo.h will automatically import the current robot's namespace into the global space. Definition at line 157 of file RobotInfo.h. Member Data Documentation
array of names for buttons -- this is the "primary" name for each button, buttonToIndex may contain additional aliases Definition at line 216 of file CommonInfo.h. Referenced by Capabilities(), DynamicInfo::DynamicCapabilities::findButtonOffset(), getButtonName(), DynamicInfo::DynamicCapabilities::getButtonOffset(), getNumButtons(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
maps button names to offset values Definition at line 219 of file CommonInfo.h. Referenced by Capabilities(), ERS220Info::ERS220Capabilities::ERS220Capabilities(), ERS7Info::ERS7Capabilities::ERS7Capabilities(), DynamicInfo::DynamicCapabilities::findButtonOffset(), findButtonOffset(), DynamicInfo::DynamicCapabilities::getButtonOffset(), getButtonOffset(), and operator=().
Offsets of "fake" outputs, which don't correspond to any physical device on the robot. This is used in compatability modes, where some outputs may not be available on the host hardware, or for meta-outputs, which control the interpretation of other outputs. (such as the A/B LED mode setting for the ERS-7, where a "virtual" LED switches the system's intepretation of the face panel LEDs). Most robots can probably just leave this empty -- on Aperios the "fake" outputs are skipped when interfacing with the system and their values receive feedback from the motion process. When using the tekkotsu executable under unix-based systems, the HAL layer handles this functionality via its own configuration settings, and these values are ignored. Definition at line 239 of file CommonInfo.h. Referenced by ERS7Info::ERS7Capabilities::ERS7Capabilities(), getFakeOutputs(), and operator=().
array of names for reference frames -- this is the "primary" name for each output/frame, frameToIndex may contain additional aliases Definition at line 215 of file CommonInfo.h. Referenced by Capabilities(), DynamicInfo::DynamicCapabilities::findFrameOffset(), DynamicInfo::DynamicCapabilities::findOutputOffset(), getFrameName(), DynamicInfo::DynamicCapabilities::getFrameOffset(), getNumFrames(), getOutputName(), DynamicInfo::DynamicCapabilities::getOutputOffset(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
maps output names to offset values Definition at line 218 of file CommonInfo.h. Referenced by Capabilities(), ChiaraInfo::ChiaraCapabilities::ChiaraCapabilities(), Chiara2Info::ChiaraCapabilities::ChiaraCapabilities(), ERS220Info::ERS220Capabilities::ERS220Capabilities(), ERS7Info::ERS7Capabilities::ERS7Capabilities(), DynamicInfo::DynamicCapabilities::findFrameOffset(), findFrameOffset(), DynamicInfo::DynamicCapabilities::findOutputOffset(), findOutputOffset(), DynamicInfo::DynamicCapabilities::getFrameOffset(), getFrameOffset(), DynamicInfo::DynamicCapabilities::getOutputOffset(), getOutputOffset(), HandEyeInfo::HandEyeCapabilities::HandEyeCapabilities(), HandEyeZInfo::HandEyeZCapabilities::HandEyeZCapabilities(), MantisInfo::MantisCapabilities::MantisCapabilities(), MantisLegInfo::MantisLegCapabilities::MantisLegCapabilities(), operator=(), QBotPlusInfo::QBotPlusCapabilities::QBotPlusCapabilities(), and Regis1Info::Regis1Capabilities::Regis1Capabilities().
the offset of the LEDs Definition at line 224 of file CommonInfo.h. Referenced by getLEDOffset(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
name of robot model Definition at line 214 of file CommonInfo.h. Referenced by getOutputOffset(), getRobotName(), lookupT(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
the number of LEDs Definition at line 225 of file CommonInfo.h. Referenced by getNumLEDs(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
the total number of outputs (e.g. the reference frames which are actuated) Definition at line 226 of file CommonInfo.h. Referenced by DynamicInfo::DynamicCapabilities::findFrameOffset(), DynamicInfo::DynamicCapabilities::findOutputOffset(), findOutputOffset(), DynamicInfo::DynamicCapabilities::getFrameOffset(), getNumOutputs(), getOutputName(), DynamicInfo::DynamicCapabilities::getOutputOffset(), getOutputOffset(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
the number of PID joints Definition at line 223 of file CommonInfo.h. Referenced by getNumPIDJoints(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
the offset of the PID joints Definition at line 222 of file CommonInfo.h. Referenced by getPIDJointOffset(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
array of names for sensors -- this is the "primary" name for each sensor, sensorToIndex may contain additional aliases Definition at line 217 of file CommonInfo.h. Referenced by Capabilities(), DynamicInfo::DynamicCapabilities::findSensorOffset(), getNumSensors(), getSensorName(), DynamicInfo::DynamicCapabilities::getSensorOffset(), DynamicInfo::DynamicCapabilities::operator=(), and operator=().
maps sensor names to offset values Definition at line 220 of file CommonInfo.h. Referenced by Capabilities(), ChiaraInfo::ChiaraCapabilities::ChiaraCapabilities(), Chiara2Info::ChiaraCapabilities::ChiaraCapabilities(), ERS7Info::ERS7Capabilities::ERS7Capabilities(), DynamicInfo::DynamicCapabilities::findSensorOffset(), findSensorOffset(), DynamicInfo::DynamicCapabilities::getSensorOffset(), getSensorOffset(), MantisLegInfo::MantisLegCapabilities::MantisLegCapabilities(), and operator=(). The documentation for this class was generated from the following files: |
Tekkotsu v5.1CVS |
Generated Mon May 9 04:59:26 2016 by Doxygen 1.6.3 |