In file /home/blah/darwin2k/src/d2k/apl/rover/roverEval.h:

class roverEvaluator

Class for evaluating rover performance on a variety of terrain test cases.

Inheritance:


Public Fields

[more] Initialization data
[more] State variables and derived values
[more] d2kComponents and dynoComponents

Public Methods

[more] roverEvaluator(void)
constructor
[more] ~roverEvaluator(void)
destructor
[more]virtual int readStandardParams(int whichCase)
Reads parameters common to all test cases
[more]virtual int initStandardParams(void)
Performs initialization common to all test cases
[more]virtual int doNextTest(void)
Performs the next test
[more]virtual int checkTermination(void)
Checks termination conditions
[more]virtual int doSimulation(void)
Main simulation loop for each test
[more]virtual int stepTest(void)
Simulates vehicle on step obstacles
[more]virtual int slopeTest(void)
Simulates vehicle on sloped, smooth terrain
[more]virtual int terrainTest(void)
Simuates the vehicle on terrain read from a file
[more]virtual int distributionTest(void)
Simulates the vehicle on a stocastically-generated terrain model
[more]virtual int evaluateInherentMetrics(void)
Evaluates metrics that are inherent properties of the vehicle
[more]virtual double checkStresses(void)
Checks structural safety factors, saving the minimum in minSafety
[more]static int deflectionCB(synObject* ev)
Callback for the postAccelHook; calls checkStresses()


Inherited from evaluator:

Public Fields

ometricSpecifierList metricSpec
optrList metrics
optrList taskParamRecs

Public Methods

ovirtual int readParams(const char* fname)
ovirtual int setVariables(const ptrList* taskParams)
ovirtual int evaluateConfiguration(void)
ovirtual int postComponentCreationHook(void)
ovirtual int postCfgInitHook(void)
ostatic evaluator* createEvaluatorFromFile(const char* evFilename)
oinline metric* getMetric(int i)
ometric* getMetricByType(const char* className)
oinline taskParamRecord* getTaskParam(int i)
oinline int numTaskParams(void)
ovoid printMetrics(FILE* fp)

Public Members

o#define getMetricByName(name)


Inherited from d2kSimulator:

Public Fields

odynamicSystem* ds
oconfiguration* cfg
optrList cfgs
optrList d2kComponents
odouble dt
odouble maxRealtime
od2kDisplayHook* display
odouble simTimeout
oulong startSecs
otriple gravity
ouniformField* gravityInfluence
oint useGravity
oint useDynamicSimulation

Public Methods

ovirtual int init(ptrList* cfgs)
ovirtual int cleanup(void)
ovirtual int dynoCleanup(void)
ovirtual int minCfgs(void) const
ovirtual int maxCfgs(void) const

Hooks for derived classes


Inherited from synObject:

Public Fields

ostatic int staticClassID
oint objectID
oint verboseLevel

Public Methods

ovirtual const char* className(void) const
ovirtual synObject* copy(void) const
ovirtual int isOfType(int typeNum, int derivedOk)
ostatic int setStaticClassID(void)
ovirtual int classID(void) const


Documentation

Class for evaluating rover performance on a variety of terrain test cases. A terrainGenerator is used to create terrain for several types of tests, and terrain objects can also be read from a file. The different test types supported by the roverEvaluator are:

The step and distribution tests can also have slopes imposed on them by altering the gravity vector. The parameters describing each test are described below under "Test case file".

P-file parameters

Test case file Parameters describing each test case are read from the file specified by 'testCaseFile' in the evaluator p-file. Parameters can be specified in the global context of the p-file, or in the case-specific context (e.g. #testCase2 for test 2). Values specified in the case-specific context override those in the global context.

The parameters are:

In addition, each specific test type has its own parameters:

fromFile

stepTest

slopeTest

distributionTest

o roverEvaluator(void)
constructor

o ~roverEvaluator(void)
destructor

o Initialization data

otriple initPos
initial position of the rover's base

oquaternion initQ
initial orientation of the rover's base

oparamParser caseParser
Parser for the test cases

odouble terrainSizeX
X size of the terrain model, in meters

odouble terrainSizeY
Y size of the terrain model, in meters

otriple terrainOrigin
origin of the terrain model, in world coordinates

odouble terrainRotation
Heading (Z rotation) of the terrain model

odouble groundMuS
static coefficient of friction for ground objects

odouble groundMuD
dynamic coefficient of friction for ground objects

odouble rockMuS
static coefficient of friction for rock objects

odouble rockMuD
dynamic coefficient of friction for rock objects

oint numTestCases
The number of test cases

odouble maxCaseTime
maximum time allotted for the test

odouble maxTotalTime
maximum time allotted for all tests

ochar testCaseFile[200]
Filename of the p-file containing test-case descriptions

oint failOnCollision
indicates whether simulation should be terminated when a chassis-terrain collision is detected

oint shortCircuit
indicates whether the evaluation should be stopped when any single test fails

odouble collisionCheckInterval
Maximum time (in seconds) between checks for chassis-terrain collisions

odouble stressCheckInterval
Maximum time (in seconds) between checks for structural safety factor

odouble totalTraverseKm
Total desired traverse length; used for computing number of motor revolutions

odouble goalY
The "finish line": when the front axle of the vehicle reaches this Y coordinate, the simulation will be terminated

odouble maxRoll
The maximum allowable vehicle roll

odouble maxPitch
The maximum allowable vehicle pitch

odouble maxXerror
the maximum allowable deviation of the base's X

odouble driveSpeed
Desired driving speed

odouble driveAcc
Desired acceleration/deceleration

oint levelBody
Indicates whether the rover should be leveled by computing a pitch angle between the frontmost and rearmost wheels and compensating for the pitch

o State variables and derived values

oint currentTest
the index of the current test

odouble lastCollisionCheckTime
time of the last collision check

odouble caseStartTime
simulation time at the start of the case

odouble timeRemaining
total time left for the simulation

ovector origState
initial rover state

odouble baseYOffset
initial Y offset of the base so that the front axle of the wheel is at initPos(1)

odouble baseRearOffset
distance from center of base to rear axle

odouble baseZOffset
initial offset of the base so that at least one wheel is touching the terrain

oint useRearForCompletion
indicates whether front or rear of rover should be used for determining when goalY is reached

oquaternion pitchQ
Rotation to level the body

odouble initialPitch
initial pitch angle after leveling body

odynoContactor* dc
the dynoContactor used for computing collisions

odouble lastStressCheckTime
time of last structural check

odouble minSafety
minimum structural safety factor measured so far

optrList toolLinks
list of links with tools attached, used for collision detection

oterrainMaterial* rockMaterial
the material to use for rocks

oterrainMaterial* soilMaterial
the material to use for soil

optrList activeMetrics
list of metrics being used for the current test case

o d2kComponents and dynoComponents

opostAccelHook* deflectionHook
a hook for checking structural safety after the robot's dynamics have been computed; calls checkStresses()

oterrainModel* tmod
The terrain model found in the list of d2kComponents. A terrain model must be specified in the p-file.

oterrainGenerator* tgen
The terrain generator found in the list of d2kComponents (optional). If no terrainGenerator is specified, then the only type of testing allowed is "terrainTest".

oroverController* ctrl
A controller for the rover (optional)

ovirtual int readStandardParams(int whichCase)
Reads parameters common to all test cases

ovirtual int initStandardParams(void)
Performs initialization common to all test cases

ovirtual int doNextTest(void)
Performs the next test

ovirtual int checkTermination(void)
Checks termination conditions

ovirtual int doSimulation(void)
Main simulation loop for each test

ovirtual int stepTest(void)
Simulates vehicle on step obstacles

ovirtual int slopeTest(void)
Simulates vehicle on sloped, smooth terrain

ovirtual int terrainTest(void)
Simuates the vehicle on terrain read from a file

ovirtual int distributionTest(void)
Simulates the vehicle on a stocastically-generated terrain model

ovirtual int evaluateInherentMetrics(void)
Evaluates metrics that are inherent properties of the vehicle

ovirtual double checkStresses(void)
Checks structural safety factors, saving the minimum in minSafety

ostatic int deflectionCB(synObject* ev)
Callback for the postAccelHook; calls checkStresses()


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.