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

ArDataLogger Class Reference

#include <ArDataLogger.h>

List of all members.


Detailed Description

This class will log data, but you have to use it through an ArConfig right now.

This class doesn't log anything by default, but can be set up to log all sorts of data. Note that if you do an addString after you do an addToConfig it'll automatically be enabled (since right now we don't want to change config after loading since the values would wind up wierd).


Public Member Functions

void addString (const char *name, ArTypes::UByte2 maxLen, ArFunctor2< char *, ArTypes::UByte2 > *functor)
 Adds a string to the list of options in the raw format.
void addToConfig (ArConfig *config)
 Adds the data logger information to the config.
 ArDataLogger (ArRobot *robot, const char *fileName=NULL)
 Constructor.
ArFunctor3< const char *,
ArTypes::UByte2, ArFunctor2<
char *, ArTypes::UByte2 > * > * 
getAddStringFunctor (void)
 Gets the functor for adding a string (for ArStringInfoGroup).
 ~ArDataLogger ()
 Destructor.

Protected Member Functions

void connectCallback (void)
bool processFile (char *errorBuffer, size_t errorBufferLen)
void userTask (void)

Protected Attributes

bool myAddedToConfig
ArFunctor3C< ArDataLogger,
const char *, ArTypes::UByte2,
ArFunctor2< char *, ArTypes::UByte2 > * > 
myAddStringFunctor
bool myAddToConfigAtConnect
int myAnalogCount
bool * myAnalogEnabled
int myAnalogVoltageCount
bool * myAnalogVoltageEnabled
ArConfigmyConfig
char myConfigFileName [512]
bool myConfigLogging
int myConfigLogInterval
ArFunctorC< ArDataLoggermyConnectCB
int myDigInCount
bool * myDigInEnabled
int myDigOutCount
bool * myDigOutEnabled
FILE * myFile
ArTime myLastLogged
bool myLogChargeState
bool myLogCorrectedEncoderPose
bool myLogEncoderPose
bool myLogEncoders
bool myLogFaultFlags
bool myLogFlags
bool myLogLeftStalled
bool myLogLeftVel
bool myLogPose
bool myLogRightStalled
bool myLogRightVel
bool myLogRotVel
bool myLogStallBits
bool myLogTransVel
bool myLogVoltage
ArTypes::UByte2 myMaxMaxLength
ArMutex myMutex
char myOpenedFileName [512]
std::string myPermanentFileName
ArRetFunctor2C< bool, ArDataLogger,
char *, size_t > 
myProcessFileCB
ArRobotmyRobot
std::vector< ArStringInfoHolder * > myStrings
int myStringsCount
std::vector< bool * > myStringsEnabled
ArFunctorC< ArDataLoggermyUserTaskCB


Constructor & Destructor Documentation

ArDataLogger::ArDataLogger ArRobot robot,
const char *  fileName = NULL
 

Constructor.

Parameters:
robot the robot to log information from
fileName if NULL then the file name is detered by the config, if not NULL then the file name data is put into, if the filename is used then the data log file is opened in append mode not in write mode, so it'll append to whats there (if you want to separate this by runs you need to do it on your own by removing or moving the file)


The documentation for this class was generated from the following files:
Generated on Thu Jan 7 10:34:41 2010 for Aria by  doxygen 1.4.2