CARMA C++
sza::util::PagerMonitor Class Reference

A class for monitoring registers to activate the pager. More...

#include <carma/szautil/PagerMonitor.h>

Classes

struct  RegSpec
 A struct for handling information about a single register. More...
 

Public Member Functions

std::vector
< PagerMonitor::RegSpec
addInRangeMonitorPoint (std::string regSpec, double min, double max, bool delta=false, unsigned nFrame=defaultNframe_, std::string comment="")
 
std::vector
< PagerMonitor::RegSpec
addMonitorPoint (std::string regSpec, DataTypeTruthFn fn, DataType &min, DataType &max, bool delta, unsigned nFrame, bool outOfRange, std::string comment)
 
std::vector
< PagerMonitor::RegSpec
addOutOfRangeMonitorPoint (std::string regSpec, double min, double max, bool delta=false, unsigned nFrame=defaultNframe_, std::string comment="")
 Methods to add a register to be monitored. More...
 
void checkRegisters ()
 
void clear ()
 
std::vector< std::string > format (std::string regSpec)
 
std::vector< std::string > getList (bool sort=false)
 
std::vector
< PagerMonitor::RegSpec
getRegs ()
 
void list ()
 
void lock ()
 
 PagerMonitor ()
 Constructor. More...
 
 PagerMonitor (ArrayDataFrameManager *source)
 
void remMonitorPoint (std::string regSpec)
 
void reset ()
 
void setHandler (MONITOR_CONDITION_HANDLER(*handler), void *arg=0)
 
void unlock ()
 
virtual ~PagerMonitor ()
 Destructor. More...
 

Friends

std::ostream & operator<< (std::ostream &os, PagerMonitor &pm)
 

Detailed Description

A class for monitoring registers to activate the pager.

The idea is to re-use the MonitorPointManager infrastructure that already exists for Can packet monitoring. This allows the user to register conditions to be checked when a register is written to, and to register handlers to be called when those conditions are met. Because these conditions are checked when registers are written, this is implemented here by copying the corresponding registers from the latest data frame into a dummy frame.

Definition at line 39 of file PagerMonitor.h.

Constructor & Destructor Documentation

sza::util::PagerMonitor::PagerMonitor ( )

Constructor.

virtual sza::util::PagerMonitor::~PagerMonitor ( )
virtual

Destructor.

Member Function Documentation

std::vector<PagerMonitor::RegSpec> sza::util::PagerMonitor::addOutOfRangeMonitorPoint ( std::string  regSpec,
double  min,
double  max,
bool  delta = false,
unsigned  nFrame = defaultNframe_,
std::string  comment = "" 
)

Methods to add a register to be monitored.


The documentation for this class was generated from the following file: