Main MRPT website > C++ reference for MRPT 1.9.9
List of all members | Public Member Functions | Public Attributes | Static Public Attributes | Protected Attributes | Private Member Functions | Static Private Member Functions
mrpt::hwdrivers::CTuMicos Class Reference

Detailed Description

This class implements initialization and comunication methods to control a Tilt Unit model DT-80, working in radians .

Definition at line 25 of file CTuMicos.h.

#include <mrpt/hwdrivers/CTuMicos.h>

Inheritance diagram for mrpt::hwdrivers::CTuMicos:
Inheritance graph

Public Member Functions

 CTuMicos ()
 Default constructor. More...
 
virtual ~CTuMicos ()
 Destructor. More...
 
virtual bool rangeMeasure ()
 Search limit forward. More...
 
virtual bool moveToAbsPos (char axis, double nRad)
 Specification of positions in absolute terms. More...
 
virtual bool absPosQ (char axis, double &nRad)
 Query position in absolute terms. More...
 
virtual bool moveToOffPos (char axis, double nRad)
 Specify desired axis position as an offset from the current position. More...
 
virtual bool offPosQ (char axis, double &nRad)
 Query position in relative terms. More...
 
virtual bool maxPosQ (char axis, double &nRad)
 Query max movement limit of a axis in absolute terms. More...
 
virtual bool minPosQ (char axis, double &nRad)
 Query min movement limit of a axis in absolute terms. More...
 
virtual bool enableLimitsQ (bool &enable)
 Query if exist movement limits. More...
 
virtual bool enableLimits (bool set)
 Enable/Disable movement limits. More...
 
virtual bool inmediateExecution (bool set)
 With I mode (default) instructs pan-tilt unit to immediately execute positional commands. More...
 
virtual bool aWait (void)
 Wait the finish of the last position command to continue accept commands. More...
 
virtual bool haltAll ()
 Inmediately stop all. More...
 
virtual bool halt (char axis)
 Inmediately stop. More...
 
virtual bool speed (char axis, double radSec)
 Specification of turn speed. More...
 
virtual bool speedQ (char axis, double &radSec)
 Query turn speed. More...
 
virtual bool aceleration (char axis, double radSec2)
 Specification (de/a)celeration in turn. More...
 
virtual bool acelerationQ (char axis, double &radSec2)
 Query (de/a)celeration in turn. More...
 
virtual bool baseSpeed (char axis, double radSec)
 Specification of velocity to which start and finish the (de/a)celeration. More...
 
virtual bool baseSpeedQ (char axis, double &radSec)
 Query velocity to which start and finish the (de/a)celeration. More...
 
virtual bool upperSpeed (char axis, double radSec)
 Specification of velocity upper limit. More...
 
virtual bool upperSpeedQ (char axis, double &radSec)
 Query velocity upper limit. More...
 
virtual bool lowerSpeed (char axis, double radSec)
 Specification of velocity lower limit. More...
 
virtual bool lowerSpeedQ (char axis, double &radSec)
 Query velocity lower limit. More...
 
virtual bool reset (void)
 Reset PTU to initial state. More...
 
virtual bool save (void)
 Save or restart default values. More...
 
virtual bool restoreDefaults (void)
 Restore default values. More...
 
virtual bool restoreFactoryDefaults (void)
 Restore factory default values. More...
 
virtual bool version (char *nVersion)
 Version and CopyRights. More...
 
virtual void nversion (double &nVersion)
 Number of version. More...
 
virtual bool powerModeQ (bool transit, char &mode)
 Query power mode. More...
 
virtual bool powerMode (bool transit, char mode)
 Specification of power mode. More...
 
bool clear ()
 Clear controller internal stack. More...
 
virtual bool setLimits (char axis, double &l, double &u)
 Set limits of movement. More...
 
virtual bool changeMotionDir ()
 
virtual int checkErrors ()
 Check errors, returns 0 if there are not errors or error code otherwise. More...
 
virtual void clearErrors ()
 Clear errors. More...
 
virtual bool init (const std::string &port)
 PTU and serial port initialization. More...
 
virtual void close ()
 Close Connection with serial port. More...
 
virtual double radError (char axis, double nRadMoved)
 To obtains the mistake for use discrete values when the movement is expressed in radians. More...
 
virtual long radToPos (char axis, double nRad)
 To obtain the discrete value for a number of radians. More...
 
virtual double posToRad (char axis, long nPos)
 To obtain the number of radians for a discrete value. More...
 
virtual bool scan (char axis, int wait, float initial, float final, double radPre)
 Performs a scan in the axis indicated and whit the precision desired. More...
 
virtual bool verboseQ (bool &modo)
 Query verbose mode. More...
 
virtual bool verbose (bool set)
 Set verbose. More...
 
virtual bool echoModeQ (bool &mode)
 Query echo mode. More...
 
virtual bool echoMode (bool mode)
 Enable/Disable echo response with command. More...
 
virtual bool resolution (void)
 Query the pan and tilt resolution per position moved and initialize local atributes. More...
 
virtual double status (double &rad)
 Check if ptu is moving. More...
 

Public Attributes

int axis_index
 
double tiltResolution
 
double panResolution
 

Static Public Attributes

static mrpt::system::TConsoleColor logging_levels_to_colors [NUMBER_OF_VERBOSITY_LEVELS]
 Map from VerbosityLevels to their corresponding mrpt::system::TConsoleColor. More...
 
static std::string logging_levels_to_names [NUMBER_OF_VERBOSITY_LEVELS]
 Map from VerbosityLevels to their corresponding names. More...
 

Protected Attributes

mrpt::comms::CSerialPort serPort
 
VerbosityLevel m_min_verbosity_level
 Provided messages with VerbosityLevel smaller than this value shall be ignored. More...
 

Private Member Functions

virtual bool transmit (const char *command)
 To transmition commands to the PTU. More...
 
virtual bool receive (const char *command, char *response)
 To receive the responseof the PTU. More...
 
virtual bool radQuerry (char axis, char command, double &nRad)
 Used to obtains a number of radians. More...
 
virtual bool radAsign (char axis, char command, double nRad)
 Method used for asign a number of radians with a command. More...
 

Static Private Member Functions

static double convertToDouble (char *sDouble)
 Convert string to double. More...
 
static long convertToLong (char *sLong)
 Convert string to long. More...
 

Logging methods

bool logging_enable_console_output
 [Default=true] Set it to false in case you don't want the logged messages to be dumped to the output automatically. More...
 
bool logging_enable_keep_record
 [Default=false] Enables storing all messages into an internal list. More...
 
void logStr (const VerbosityLevel level, const std::string &msg_str) const
 Main method to add the specified message string to the logger. More...
 
void logFmt (const VerbosityLevel level, const char *fmt,...) const MRPT_printf_format_check(3
 Alternative logging method, which mimics the printf behavior. More...
 
void void logCond (const VerbosityLevel level, bool cond, const std::string &msg_str) const
 Log the given message only if the condition is satisfied. More...
 
void setLoggerName (const std::string &name)
 Set the name of the COutputLogger instance. More...
 
std::string getLoggerName () const
 Return the name of the COutputLogger instance. More...
 
void setMinLoggingLevel (const VerbosityLevel level)
 Set the minimum logging level for which the incoming logs are going to be taken into account. More...
 
void setVerbosityLevel (const VerbosityLevel level)
 alias of setMinLoggingLevel() More...
 
VerbosityLevel getMinLoggingLevel () const
 
bool isLoggingLevelVisible (VerbosityLevel level) const
 
void getLogAsString (std::string &log_contents) const
 Fill the provided string with the contents of the logger's history in std::string representation. More...
 
std::string getLogAsString () const
 Get the history of COutputLogger instance in a string representation. More...
 
void writeLogToFile (const std::string *fname_in=NULL) const
 Write the contents of the COutputLogger instance to an external file. More...
 
void dumpLogToConsole () const
 Dump the current contents of the COutputLogger instance in the terminal window. More...
 
std::string getLoggerLastMsg () const
 Return the last Tmsg instance registered in the logger history. More...
 
void getLoggerLastMsg (std::string &msg_str) const
 Fill inputtted string with the contents of the last message in history. More...
 
void loggerReset ()
 Reset the contents of the logger instance. More...
 
void logRegisterCallback (output_logger_callback_t userFunc)
 
bool logDeregisterCallback (output_logger_callback_t userFunc)
 

Constructor & Destructor Documentation

◆ CTuMicos()

mrpt::hwdrivers::CTuMicos::CTuMicos ( )
inline

Default constructor.

Definition at line 30 of file CTuMicos.h.

◆ ~CTuMicos()

virtual mrpt::hwdrivers::CTuMicos::~CTuMicos ( )
inlinevirtual

Destructor.

Definition at line 34 of file CTuMicos.h.

References close().

Member Function Documentation

◆ absPosQ()

bool CTuMicos::absPosQ ( char  axis,
double &  nRad 
)
virtual

Query position in absolute terms.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 63 of file CTuMicos.cpp.

◆ aceleration()

bool CTuMicos::aceleration ( char  axis,
double  radSec2 
)
virtual

Specification (de/a)celeration in turn.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 131 of file CTuMicos.cpp.

◆ acelerationQ()

bool CTuMicos::acelerationQ ( char  axis,
double &  radSec2 
)
virtual

Query (de/a)celeration in turn.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 142 of file CTuMicos.cpp.

◆ aWait()

bool CTuMicos::aWait ( void  )
virtual

Wait the finish of the last position command to continue accept commands.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 252 of file CTuMicos.cpp.

◆ baseSpeed()

bool CTuMicos::baseSpeed ( char  axis,
double  radSec 
)
virtual

Specification of velocity to which start and finish the (de/a)celeration.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 153 of file CTuMicos.cpp.

◆ baseSpeedQ()

bool CTuMicos::baseSpeedQ ( char  axis,
double &  radSec 
)
virtual

Query velocity to which start and finish the (de/a)celeration.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 164 of file CTuMicos.cpp.

◆ changeMotionDir()

bool CTuMicos::changeMotionDir ( )
virtual

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 406 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ checkErrors()

int CTuMicos::checkErrors ( )
virtual

Check errors, returns 0 if there are not errors or error code otherwise.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 782 of file CTuMicos.cpp.

◆ clear()

bool CTuMicos::clear ( )

Clear controller internal stack.

Definition at line 378 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ clearErrors()

virtual void mrpt::hwdrivers::CTuMicos::clearErrors ( )
inlinevirtual

Clear errors.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 214 of file CTuMicos.h.

◆ close()

void CTuMicos::close ( )
virtual

Close Connection with serial port.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 494 of file CTuMicos.cpp.

Referenced by ~CTuMicos().

◆ convertToDouble()

double CTuMicos::convertToDouble ( char *  sDouble)
staticprivate

Convert string to double.

Definition at line 770 of file CTuMicos.cpp.

◆ convertToLong()

long CTuMicos::convertToLong ( char *  sLong)
staticprivate

Convert string to long.

Definition at line 759 of file CTuMicos.cpp.

◆ dumpLogToConsole()

void COutputLogger::dumpLogToConsole ( ) const
inherited

Dump the current contents of the COutputLogger instance in the terminal window.

See also
writeToFile

Definition at line 179 of file COutputLogger.cpp.

◆ echoMode()

bool CTuMicos::echoMode ( bool  mode)
virtual

Enable/Disable echo response with command.


Example of use (EE supposed):
PP * 22
ED *
<pp entered again, but not echoed>* 22

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 605 of file CTuMicos.cpp.

◆ echoModeQ()

bool CTuMicos::echoModeQ ( bool &  mode)
virtual

Query echo mode.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 594 of file CTuMicos.cpp.

◆ enableLimits()

bool CTuMicos::enableLimits ( bool  set)
virtual

Enable/Disable movement limits.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 230 of file CTuMicos.cpp.

◆ enableLimitsQ()

bool CTuMicos::enableLimitsQ ( bool &  enable)
virtual

Query if exist movement limits.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 219 of file CTuMicos.cpp.

◆ getLogAsString() [1/2]

void COutputLogger::getLogAsString ( std::string log_contents) const
inherited

Fill the provided string with the contents of the logger's history in std::string representation.

Definition at line 143 of file COutputLogger.cpp.

◆ getLogAsString() [2/2]

std::string COutputLogger::getLogAsString ( ) const
inherited

Get the history of COutputLogger instance in a string representation.

Definition at line 148 of file COutputLogger.cpp.

Referenced by mrpt::graphslam::deciders::CICPCriteriaNRD< GRAPH_T >::getDescriptiveReport().

◆ getLoggerLastMsg() [1/2]

std::string COutputLogger::getLoggerLastMsg ( ) const
inherited

Return the last Tmsg instance registered in the logger history.

Definition at line 184 of file COutputLogger.cpp.

References mrpt::system::COutputLogger::TMsg::getAsString().

◆ getLoggerLastMsg() [2/2]

void COutputLogger::getLoggerLastMsg ( std::string msg_str) const
inherited

Fill inputtted string with the contents of the last message in history.

Definition at line 190 of file COutputLogger.cpp.

◆ getLoggerName()

std::string COutputLogger::getLoggerName ( ) const
inherited

Return the name of the COutputLogger instance.

See also
setLoggerName

Definition at line 132 of file COutputLogger.cpp.

Referenced by mrpt::system::COutputLogger::TMsg::TMsg().

◆ getMinLoggingLevel()

VerbosityLevel mrpt::system::COutputLogger::getMinLoggingLevel ( ) const
inlineinherited

◆ halt()

bool CTuMicos::halt ( char  axis)
virtual

Inmediately stop.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 268 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ haltAll()

bool CTuMicos::haltAll ( )
virtual

Inmediately stop all.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 257 of file CTuMicos.cpp.

◆ init()

bool CTuMicos::init ( const std::string port)
virtual

PTU and serial port initialization.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 432 of file CTuMicos.cpp.

References mrpt::containers::clear(), and MRPT_LOG_ERROR_STREAM.

◆ inmediateExecution()

bool CTuMicos::inmediateExecution ( bool  set)
virtual

With I mode (default) instructs pan-tilt unit to immediately execute positional commands.


In S mode instructs pan-tilt unit to execute positional commands only when an Await Position Command Completion command is executed or when put into Immediate Execution Mode.

Example of use of S mode:
DR *
S *
PP1500 *
TP-900 *
PP * Current Pan position is 0
TP * Current Tilt position is 0
A *
PP * Current Pan position is 1500
TP * Current Tilt position is -900

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 241 of file CTuMicos.cpp.

◆ isLoggingLevelVisible()

bool mrpt::system::COutputLogger::isLoggingLevelVisible ( VerbosityLevel  level) const
inlineinherited

◆ logCond()

void COutputLogger::logCond ( const VerbosityLevel  level,
bool  cond,
const std::string msg_str 
) const
inherited

Log the given message only if the condition is satisfied.

See also
log, logFmt

Definition at line 120 of file COutputLogger.cpp.

◆ logDeregisterCallback()

bool COutputLogger::logDeregisterCallback ( output_logger_callback_t  userFunc)
inherited
Returns
true if an entry was found and deleted.

Definition at line 287 of file COutputLogger.cpp.

References getAddress().

◆ logFmt()

void COutputLogger::logFmt ( const VerbosityLevel  level,
const char *  fmt,
  ... 
) const
inherited

◆ loggerReset()

void COutputLogger::loggerReset ( )
inherited

Reset the contents of the logger instance.

Called upon construction.

Definition at line 195 of file COutputLogger.cpp.

References mrpt::system::LVL_INFO.

◆ logRegisterCallback()

void COutputLogger::logRegisterCallback ( output_logger_callback_t  userFunc)
inherited

Definition at line 274 of file COutputLogger.cpp.

◆ logStr()

void COutputLogger::logStr ( const VerbosityLevel  level,
const std::string msg_str 
) const
inherited

◆ lowerSpeed()

bool CTuMicos::lowerSpeed ( char  axis,
double  radSec 
)
virtual

Specification of velocity lower limit.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 197 of file CTuMicos.cpp.

◆ lowerSpeedQ()

bool CTuMicos::lowerSpeedQ ( char  axis,
double &  radSec 
)
virtual

Query velocity lower limit.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 208 of file CTuMicos.cpp.

References DEG2RAD.

◆ maxPosQ()

bool CTuMicos::maxPosQ ( char  axis,
double &  nRad 
)
virtual

Query max movement limit of a axis in absolute terms.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 95 of file CTuMicos.cpp.

◆ minPosQ()

bool CTuMicos::minPosQ ( char  axis,
double &  nRad 
)
virtual

Query min movement limit of a axis in absolute terms.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 104 of file CTuMicos.cpp.

◆ moveToAbsPos()

bool CTuMicos::moveToAbsPos ( char  axis,
double  nRad 
)
virtual

Specification of positions in absolute terms.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 49 of file CTuMicos.cpp.

References RAD2DEG, and mrpt::system::os::sprintf().

◆ moveToOffPos()

bool CTuMicos::moveToOffPos ( char  axis,
double  nRad 
)
virtual

Specify desired axis position as an offset from the current position.


This method recives the number of radians to move.

Example of use:
TT-500 *
A *
TO * Current Tilt position is -500
TO500 *
A *
TT * Current Pan position is 1000

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 72 of file CTuMicos.cpp.

References RAD2DEG, and mrpt::system::os::sprintf().

◆ nversion()

void CTuMicos::nversion ( double &  nVersion)
virtual

Number of version.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 346 of file CTuMicos.cpp.

◆ offPosQ()

bool CTuMicos::offPosQ ( char  axis,
double &  nRad 
)
virtual

Query position in relative terms.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 86 of file CTuMicos.cpp.

◆ posToRad()

double CTuMicos::posToRad ( char  axis,
long  nPos 
)
virtual

To obtain the number of radians for a discrete value.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 748 of file CTuMicos.cpp.

◆ powerMode()

bool CTuMicos::powerMode ( bool  transit,
char  mode 
)
virtual

Specification of power mode.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 367 of file CTuMicos.cpp.

◆ powerModeQ()

bool CTuMicos::powerModeQ ( bool  transit,
char &  mode 
)
virtual

Query power mode.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 356 of file CTuMicos.cpp.

◆ radAsign()

bool CTuMicos::radAsign ( char  axis,
char  command,
double  nRad 
)
privatevirtual

Method used for asign a number of radians with a command.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 709 of file CTuMicos.cpp.

References RAD2DEG, and mrpt::system::os::sprintf().

◆ radError()

double CTuMicos::radError ( char  axis,
double  nRadMoved 
)
virtual

To obtains the mistake for use discrete values when the movement is expressed in radians.

Parameters are the absolute position in radians and the axis desired

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 508 of file CTuMicos.cpp.

◆ radQuerry()

bool CTuMicos::radQuerry ( char  axis,
char  command,
double &  nRad 
)
privatevirtual

Used to obtains a number of radians.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 632 of file CTuMicos.cpp.

References DEG2RAD, mrpt::system::os::sprintf(), and mrpt::system::strtok().

◆ radToPos()

long CTuMicos::radToPos ( char  axis,
double  nRad 
)
virtual

To obtain the discrete value for a number of radians.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 737 of file CTuMicos.cpp.

◆ rangeMeasure()

bool CTuMicos::rangeMeasure ( )
virtual

Search limit forward.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 29 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ receive()

bool CTuMicos::receive ( const char *  command,
char *  response 
)
privatevirtual

To receive the responseof the PTU.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 542 of file CTuMicos.cpp.

References mrpt::system::os::strcpy().

◆ reset()

bool CTuMicos::reset ( void  )
virtual

Reset PTU to initial state.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 282 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ resolution()

bool CTuMicos::resolution ( void  )
virtual

Query the pan and tilt resolution per position moved and initialize local atributes.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 616 of file CTuMicos.cpp.

◆ restoreDefaults()

bool CTuMicos::restoreDefaults ( void  )
virtual

Restore default values.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 313 of file CTuMicos.cpp.

◆ restoreFactoryDefaults()

bool CTuMicos::restoreFactoryDefaults ( void  )
virtual

Restore factory default values.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 324 of file CTuMicos.cpp.

◆ save()

bool CTuMicos::save ( void  )
virtual

Save or restart default values.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 302 of file CTuMicos.cpp.

◆ scan()

bool CTuMicos::scan ( char  axis,
int  wait,
float  initial,
float  final,
double  radPre 
)
virtual

Performs a scan in the axis indicated and whit the precision desired.


Parameters
<axis>{Pan or Till}
<tWait>{Wait time betwen commands}
<initial>{initial position}
<final>{final position}
<radPre>{radians precision for the scan}

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 725 of file CTuMicos.cpp.

◆ setLimits()

bool CTuMicos::setLimits ( char  axis,
double &  l,
double &  u 
)
virtual

Set limits of movement.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 392 of file CTuMicos.cpp.

References mrpt::system::os::sprintf().

◆ setLoggerName()

void COutputLogger::setLoggerName ( const std::string name)
inherited

◆ setMinLoggingLevel()

void COutputLogger::setMinLoggingLevel ( const VerbosityLevel  level)
inherited

Set the minimum logging level for which the incoming logs are going to be taken into account.

String messages with specified VerbosityLevel smaller than the min, will not be outputted to the screen and neither will a record of them be stored in by the COutputLogger instance

Definition at line 133 of file COutputLogger.cpp.

Referenced by mrpt::maps::CRandomFieldGridMap2D::enableVerbose(), mrpt::math::CLevenbergMarquardtTempl< VECTORTYPE, USERPARAM >::execute(), mrpt::hwdrivers::CHokuyoURG::initialize(), and mrpt::graphslam::deciders::CICPCriteriaNRD< GRAPH_T >::loadParams().

◆ setVerbosityLevel()

void COutputLogger::setVerbosityLevel ( const VerbosityLevel  level)
inherited

◆ speed()

bool CTuMicos::speed ( char  axis,
double  radSec 
)
virtual

Specification of turn speed.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 113 of file CTuMicos.cpp.

◆ speedQ()

bool CTuMicos::speedQ ( char  axis,
double &  radSec 
)
virtual

Query turn speed.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 122 of file CTuMicos.cpp.

◆ status()

double CTuMicos::status ( double &  rad)
virtual

Check if ptu is moving.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 627 of file CTuMicos.cpp.

◆ transmit()

bool CTuMicos::transmit ( const char *  command)
privatevirtual

To transmition commands to the PTU.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 519 of file CTuMicos.cpp.

References mrpt::system::os::strcat(), and mrpt::system::os::strcpy().

◆ upperSpeed()

bool CTuMicos::upperSpeed ( char  axis,
double  radSec 
)
virtual

Specification of velocity upper limit.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 175 of file CTuMicos.cpp.

◆ upperSpeedQ()

bool CTuMicos::upperSpeedQ ( char  axis,
double &  radSec 
)
virtual

Query velocity upper limit.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 186 of file CTuMicos.cpp.

References DEG2RAD.

◆ verbose()

bool CTuMicos::verbose ( bool  set)
virtual

Set verbose.


Example of response with FV (verbose) active: FV * PP * Current pan position is 0 Example of response with FT (terse) active: FT * PP * 0

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 583 of file CTuMicos.cpp.

◆ verboseQ()

bool CTuMicos::verboseQ ( bool &  modo)
virtual

Query verbose mode.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 572 of file CTuMicos.cpp.

◆ version()

bool CTuMicos::version ( char *  nVersion)
virtual

Version and CopyRights.

Implements mrpt::hwdrivers::CPtuBase.

Definition at line 335 of file CTuMicos.cpp.

◆ writeLogToFile()

void COutputLogger::writeLogToFile ( const std::string fname_in = NULL) const
inherited

Write the contents of the COutputLogger instance to an external file.

Upon call to this method, COutputLogger dumps the contents of all the logged commands so far to the specified external file. By default the filename is set to ${LOGGERNAME}.log except if the fname parameter is provided

See also
dumpToConsole, getAsString

Definition at line 154 of file COutputLogger.cpp.

References ASSERTMSG_, and mrpt::format().

Member Data Documentation

◆ axis_index

int mrpt::hwdrivers::CTuMicos::axis_index

Definition at line 326 of file CTuMicos.h.

◆ logging_enable_console_output

bool mrpt::system::COutputLogger::logging_enable_console_output
inherited

[Default=true] Set it to false in case you don't want the logged messages to be dumped to the output automatically.

Definition at line 239 of file system/COutputLogger.h.

◆ logging_enable_keep_record

bool mrpt::system::COutputLogger::logging_enable_keep_record
inherited

[Default=false] Enables storing all messages into an internal list.

See also
writeLogToFile, getLogAsString

Definition at line 242 of file system/COutputLogger.h.

◆ logging_levels_to_colors

mrpt::system::TConsoleColor COutputLogger::logging_levels_to_colors
staticinherited
Initial value:

Map from VerbosityLevels to their corresponding mrpt::system::TConsoleColor.

Implementation file for the COutputLogger header class.

Handy for coloring the input based on the verbosity of the message

Definition at line 124 of file system/COutputLogger.h.

Referenced by mrpt::system::COutputLogger::TMsg::dumpToConsole().

◆ logging_levels_to_names

std::string COutputLogger::logging_levels_to_names
staticinherited
Initial value:
=
{
"DEBUG",
"INFO ",
"WARN ",
"ERROR"
}

Map from VerbosityLevels to their corresponding names.

Handy for printing the current message VerbosityLevel along with the actual content

Definition at line 129 of file system/COutputLogger.h.

Referenced by mrpt::system::COutputLogger::TMsg::getAsString().

◆ m_min_verbosity_level

VerbosityLevel mrpt::system::COutputLogger::m_min_verbosity_level
protectedinherited

Provided messages with VerbosityLevel smaller than this value shall be ignored.

Definition at line 252 of file system/COutputLogger.h.

Referenced by mrpt::system::COutputLogger::getMinLoggingLevel(), and mrpt::system::COutputLogger::isLoggingLevelVisible().

◆ panResolution

double mrpt::hwdrivers::CPtuBase::panResolution
inherited

Definition at line 28 of file CPtuBase.h.

◆ serPort

mrpt::comms::CSerialPort mrpt::hwdrivers::CPtuBase::serPort
protectedinherited

Definition at line 31 of file CPtuBase.h.

◆ tiltResolution

double mrpt::hwdrivers::CPtuBase::tiltResolution
inherited

Definition at line 28 of file CPtuBase.h.




Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: ad3a9d8ae Tue May 1 23:10:22 2018 -0700 at lun oct 28 00:14:14 CET 2019