LRAUV  revA
ESPComponent Class Reference

Sensor component to interface with the ESP. More...

#include <ESPComponent.h>

Inheritance diagram for ESPComponent:
Collaboration diagram for ESPComponent:

Public Member Functions

 ESPComponent (const Module *module)
 Testing with simulators on bufflehead and tethyssim: More...
 
virtual ~ESPComponent ()
 
virtual void run ()
 The actual "payload" of the component. More...
 
virtual RunState start ()
 Do what needs to be done to run Similar to initialize, in old init/run/uninit sequence. More...
 
virtual RunState starting ()
 Might follow a STOP...START sequence. More...
 
virtual RunState pause ()
 Pause for a short period (indicated by pauseTime) More...
 
virtual RunState paused ()
 Should eventually follow a PAUSE request: should set continueTime. More...
 
virtual RunState resume ()
 Resume from PAUSE. More...
 
virtual RunState resuming ()
 Might follow a PAUSE...RESUME sequence. More...
 
virtual RunState runnable ()
 Should eventually follow a START request or RESETTING. More...
 
virtual RunState resetting ()
 Might occur in case of Error. More...
 
virtual RunState stop ()
 Initial state – can be later followed by START. More...
 
virtual RunState stopping ()
 Might follow a STOP request. More...
 
virtual RunState stopped ()
 Initial state – can be later followed by START. More...
 
void uninitialize ()
 Provide a space for uninitialization. More...
 
virtual ConfigURI getConfigURI (ConfigOption configOption) const
 Should return [myNamespace]::SIMULATE_HARDWARE, or [myNamespace]::POWER, etc. More...
 
- Public Member Functions inherited from SyncComponent
CycleOrder getCycleOrder (void)
 Getter function for controlThreadOrderPreference. More...
 
void setRepeating (bool repeating)
 
int getDivisor () const
 
int getModulo () const
 
bool isRepeater ()
 
bool isRepeating ()
 
- Public Member Functions inherited from Component
virtual ~Component ()
 Destructor cleans up readers_ and writers_. More...
 
void registerReader (DataReader *reader)
 
void unregisterReader (DataReader *reader)
 
void registerWriter (DataWriter *writer)
 
void unregisterWriter (DataWriter *writer)
 
void disableMetering (void)
 
FlexArray< DataReader * > & getReaderList (void)
 
FlexArray< DataWriter * > & getWriterList (void)
 
const ModulegetModule ()
 
virtual void initialize ()
 Provide a space for initialization before being run. More...
 
virtual void configure ()
 Read (or re-read!) configuration settings. More...
 
virtual void execute (void)
 
bool isActive () const
 Indicates if the component is active. More...
 
const CodedStrgetName (void) const
 Returns the name. More...
 
const TimestampgetTimeOfLastRun (void) const
 
ComponentState getState (void)
 Return the component's current state. More...
 
void setState (ComponentState state)
 
RunState getRunState (void)
 Return the component's run state. More...
 
bool isUsingRunState ()
 Return true if using runState. More...
 
void requestData (bool requestingData)
 Tell the component to start (or stop) sending data. More...
 
void requestStart ()
 Tell the component to start runnning. More...
 
void requestPause (const Timespan expectedPauseTime)
 Tell the component to pause runnning. More...
 
void requestResume ()
 Tell the component resume from pause. More...
 
void requestStop ()
 Tell the component to stop runnning. More...
 
virtual RunState satisfied ()
 Possible return value of a Behavior. More...
 
virtual RunState pausing ()
 Might follow a PAUSE request. More...
 
void setCriticalFailureReported (bool boolVal)
 
void setRecoveringFromCritical (bool boolVal)
 
void setFailureReported (bool boolVal)
 
bool isFailureUninitialized ()
 
void setFailureUninitialized (bool boolVal)
 
void setRetryTimeout (const Timespan &timeout)
 
virtual bool isCompleted (void)
 Query if this component is completed. More...
 
void setPeriod (const Timespan &period)
 Set the period of this component... used if it is periodic. More...
 
const TimespangetPeriod (void)
 Returns the component's period (regardless of whether it is periodic) More...
 
ComponentType getComponentType ()
 Getter function for ComponentType. More...
 
virtual bool isFailed (void) const
 
virtual FailureMode::FailType getFailureType (void) const
 
virtual bool getCriticalFailureReported (void) const
 
virtual bool getFailureReported (void) const
 
virtual Timespan getRetryTimeout (void) const
 
virtual FailureMode::FailType setFailure (FailureMode::FailType failureType)
 
virtual int getFailCount (void) const
 
virtual bool isFailureMissionCritical ()
 
virtual int getAllowableFailures (void) const
 
virtual void setAllowableFailures (int fails)
 
LoggergetLogger (void)
 
virtual int incrementFailCount (void)
 
virtual void resetFailCount (void)
 
virtual int getSkippedRunsSinceFail (void) const
 
virtual int incrementSkippedRunsSinceFail (void)
 
virtual void logVoltage (float voltage, float averageVoltage)
 
virtual void logCurrent (float current, float averageCurrent)
 
const TimestampgetWriteTimestamp (void)
 
void setWriteTimestamp (const Timestamp &writeTimestamp)
 
BlobReadernewBlobReader (const BlobURI &blobURI)
 
BlobReadernewBlobReaderFromUniversal (const Str &componentName, const UniversalBlobURI &blobURI)
 
BlobWriternewBlobWriter (const BlobURI &blobURI, Logger::TimePrecisionType timePrecision=Logger::TIME_PRECISION_MILLIS)
 
ConfigReadernewConfigReader (const ConfigURI &configURI)
 
DataReadernewDataReader (const DataURI &dataURI)
 
DataReadernewDataReaderFromUniversal (const Str &componentName, const UniversalURI &universalURI)
 
DataWriternewDataWriter (const DataURI &dataURI, Logger::TimePrecisionType timePrecision=Logger::TIME_PRECISION_MILLIS)
 
UniversalBlobReadernewUniversalBlobReader (const UniversalBlobURI &universalURI)
 
UniversalBlobWriternewUniversalBlobWriter (const UniversalBlobURI &universalURI, const Unit &accuracyUnit=Units::NONE, const float accuracy=DataElement::NO_ACCURACY, Logger::TimePrecisionType timePrecision=Logger::TIME_PRECISION_MILLIS)
 
UniversalDataReadernewUniversalReader (const UniversalURI &universalURI)
 
UniversalDataWriternewUniversalWriter (const UniversalURI &universalURI, const Unit &accuracyUnit=Units::NONE, const float accuracy=DataElement::NO_ACCURACY, Logger::TimePrecisionType timePrecision=Logger::TIME_PRECISION_MILLIS)
 

Private Types

enum  StartState {
  SS_INIT, SS_CONNECTING_AS_CLIENT, SS_WAITING_FOR_ESP_TO_CONNECT, SS_WAITING_FOR_PORT_NUMBER,
  SS_CONNECTED
}
 Sub-states while in LRAUV framework's STARTING state. More...
 

Private Member Functions

 ESPComponent (const ESPComponent &old)
 
const char * startStateName (StartState startState)
 
void createESPComm ()
 Creates espComm_ in specific mode (LRAUV either as server or client) depending on espServerHost_ (and using socketServerPort_ if LRAUV is to be server). More...
 
void createESPClient ()
 Creates espClient_. More...
 
bool openServerSocket ()
 opens server socket to listen for ESP connection More...
 
bool powerUpESP ()
 powers up ESP and initiates PPP link More...
 
bool powerDownESP (bool setFailure=true)
 powers down ESP and brings down PPP link. More...
 
Component::RunState waitForESPConnection ()
 Once the ESP is powered up, we wait for the ESP to connect. More...
 
bool scanEspServerPort (Str &line, int *espServerPort)
 Once the ESP is connected as a client, we expect a first line indicating the port it is listening on as a server. More...
 
void espReady ()
 ESP connection ready. More...
 
Component::RunState startSamplingPhase ()
 Starts a sampling phase. More...
 
int getLine (Str &line)
 Expects next line from the ESP. More...
 
bool isDataRequested ()
 
bool logVoltageAndCurrent ()
 
bool getSimulatedData ()
 
void writeData ()
 
void startPPP (void)
 
void stopPPP (void)
 
bool readConfigs ()
 
bool readAdjustableConfigs ()
 
void logDebug (Str msg)
 

Private Attributes

StartState startState_
 
ESPCommespComm_
 The base communications interface to the ESP. More...
 
ESPClientespClient_
 High-level logic for interactions with the ESP. More...
 
ESPClient::SamplingState samplingState_
 
Str partialLine_
 
UartStream uart_
 Power and comms in this case. More...
 
LoadControlloadControl_
 
ConfigReaderdebugCfgReader_
 
ConfigReadersocketServerPortCfgReader_
 
ConfigReaderespServerHostCfgReader_
 
ConfigReaderpoTimeoutCfgReader_
 
ConfigReaderconnectTimeoutCfgReader_
 
ConfigReadersampleTimeoutCfgReader_
 
ConfigReaderinitialPromptTimeoutCfgReader_
 
ConfigReaderloadCartridgeTimeoutCfgReader_
 
ConfigReaderfilterResultTimeoutCfgReader_
 
ConfigReaderfilterCompleteTimeoutCfgReader_
 
ConfigReaderprocessResultTimeoutCfgReader_
 
ConfigReaderprocessCompleteTimeoutCfgReader_
 
ConfigReaderstopResultTimeoutCfgReader_
 
int socketServerPort_
 
StrValue espServerHost_
 Typically this will the empty string from configuration, meaning that the LRAUV will power-up and down the ESP as part of an overall sampling sequence. More...
 
bool espAlwaysServer_
 true if and only if espServerHost_ is non-empty and has the format "hostname:portNumber" More...
 
Timespan poTimeout_
 Timeouts. More...
 
Timespan connectTimeout_
 
Timespan sampleTimeout_
 
Timespan initialPromptTimeout_
 
Timespan loadCartridgeTimeout_
 
Timespan filterResultTimeout_
 
Timespan filterCompleteTimeout_
 
Timespan processResultTimeout_
 
Timespan processCompleteTimeout_
 
Timespan stopResultTimeout_
 
Timespan lineTimeout_
 
Timestamp startTimeAccept_
 Time prior to accept ESP client connection: More...
 
Timestamp startTimeForLine_
 Time prior to expecting a line from ESP: More...
 
Timestamp startTimeConnecting_
 Time prior to connecting as client to the ESP: More...
 
Timestamp sampleTime_
 Time when sampling started. More...
 
bool samplingActive_
 
int sampleNumber_
 
bool debug_
 Debugging outputs. More...
 
StrValue connectExec_
 
StrValue pppFlow_
 
StrValue uartName_
 
Str pppCmd_
 
DataWritersamplingActiveWriter_
 
DataWritersampleNumberWriter_
 

Additional Inherited Members

- Public Types inherited from Component
enum  ComponentState {
  BLOCK_CONTINUOUS, BLOCK_PERIODIC, BLOCK_NORMAL, BLOCK_COMPLETED,
  BLOCK_UNKNOWN
}
 In this model, the component has basically two states: wanting to run, and completed (no longer needing to run). More...
 
enum  ComponentType { COMPONENT_ASYNC, COMPONENT_CONFIG, COMPONENT_BEHAVIOR, COMPONENT_SYNC }
 Components can indicate how they want to be handled by their type. More...
 
enum  RunState {
  NO_RUN_STATE = 0, START, STARTING, RUNNABLE,
  SATISFIED, PAUSE, PAUSING, PAUSED,
  RESUME, RESUMING, RESETTING, STOP,
  STOPPING, STOPPED
}
 
- Static Public Attributes inherited from SyncComponent
static const int CYCLE_INCREMENT
 
static const int CYCLE_REPEAT_OFFSET
 
static const CycleOrder CYCLE_STARTER
 
static const CycleOrder CYCLE_SIMULATOR
 
static const CycleOrder CYCLE_SENSOR
 
static const CycleOrder CYCLE_DERIVATION
 
static const CycleOrder CYCLE_ESTIMATION
 
static const CycleOrder CYCLE_NAVIGATION
 
static const CycleOrder CYCLE_MISSION_MANAGER
 
static const CycleOrder CYCLE_MISSION
 
static const CycleOrder CYCLE_CONTROL
 
static const CycleOrder CYCLE_SERVO
 
static const CycleOrder CYCLE_TEST
 
static const CycleOrder CYCLE_REPORTER
 
static const CycleOrder CYCLE_LOGGER
 
- Protected Types inherited from Component
enum  ConfigOption { CONFIG_SIMULATE_HARDWARE, CONFIG_POWER, CONFIG_FREQUENCY, CONFIG_LATENCY }
 
- Protected Member Functions inherited from SyncSensorComponent
 SyncSensorComponent (const Str &name, const Module *module, int divisor=1, int modulo=0)
 
- Protected Member Functions inherited from SyncComponent
void setRepeater (bool repeater)
 
- Protected Member Functions inherited from Component
virtual ConfigURI getConfigURI (ConfigOption configOption, ElementURI forElement) const
 Should return [myNamespace]::POWER_[forElement], [myNamespace]::LATENCY_[forElement], etc. More...
 
virtual void setDurationOfLastRun (const Timespan &span)
 
virtual void setTimeOfRun (const Timestamp &time)
 
virtual void setTimeOfLastRun (const Timestamp &time)
 
virtual void setDt (const Timespan &dt)
 
virtual bool setEnabled (bool enabled=true)
 
void setRunState (const RunState runState)
 
const Timespan getPauseTime () const
 
virtual void setFailureMissionCritical (bool failureMissionCritical)
 
bool simulateHardware ()
 
- Protected Attributes inherited from Component
Logger logger_
 
Syslog::Severity debugLevel_
 
ComponentState state_
 Keep track of whether the component has "completed" or should be run again. More...
 
Timespan desiredPeriod_
 
CodedStrname_
 Store the component's name (used for logging purposes) More...
 
Timestamp timeOfRun_
 
Timestamp timeOfLastRun_
 
Timespan durationOfLastRun_
 
Timespan dt_
 
Timespan retryTimeout_
 
bool enabled_
 
bool failureReported_
 Indicates if the failure has been reported – cuts down on syslog. More...
 
bool criticalFailureReported_
 Indicates if a "Critical" failure has been reported – cuts down on syslog. More...
 
bool recoveringFromCritical_
 Indicates that a component had a previous critical failure that has been cleared temporarily awaiting final word from the component itself. More...
 
bool failureUninitialized_
 Indicates if the failure has resulted in an uninitialize call. More...
 
int failCount_
 Number of failures logged by PCaller. More...
 
bool failureMissionCritical_
 If true (default), complete failure ends mission. More...
 
int allowableFailures_
 Number of failures allowed to occur. More...
 
int skippedRunsSinceFail_
 Number of skipped runs since failureMode_ set by failCount_. More...
 
FailureMode::FailType failureType_
 Failed status. If failCount_ > 0, then this may be reset. More...
 
Timestamp timeOfFailure_
 Time of last failure. Relevant only if failed=true. More...
 
Timestamp writeTimestamp_
 Time of last write. More...
 
FlexArray< DataReader * > readers_
 
FlexArray< DataWriter * > writers_
 
const Modulemodule_
 
Timespan pauseTime_
 
bool meteringEnabled_
 If true, metering is enabled. More...
 
DataWriterdurationOfLastRunWriter_
 Writer for durationOfLastRun. More...
 
DataWritervoltageWriter_
 
DataWriteravgVoltageWriter_
 
DataWritercurrentWriter_
 
DataWriteravgCurrentWriter_
 
bool persistentPause_
 True if data is persistent while component is paused. More...
 

Detailed Description

Sensor component to interface with the ESP.

Uses ESPComm for the base communication layer with the ESP. Uses ESPClient for the high-level logic for interactions with the ESP.

Constructor & Destructor Documentation

ESPComponent::ESPComponent ( const Module module)

Testing with simulators on bufflehead and tethyssim:

See example of complete session at https://bitbucket.org/snippets/carueda/8KR6B

(Note: the config parameter ESPComponent.simulateHardware is false for these tests: the ESP simulator is still an external process and we interact with it from here as if it were a real ESP.)

On bufflehead, where an image of the ESP software is ready to be exercised (under carueda's home):

$ cd esp2
$ . bin/ESPenv auv honu
$ ESPmode=simreal

Make sure the ESP simulator has enough "dry" cartridges. For this you can simply run Cmd.slot All=>:dry:

$ esp
-> Cmd.slot All=>:dry
{All => :dry}
-> Cmd.map
{1 => :dry,
2 => :dry,
3 => :dry,
4 => :dry,
5 => :dry}
-> exit # note, exit the ESP simulator herre for what follows.

Then, in this bufflehead session prepare the following command but do not launch it yet:

$ ESPclient=tethyssim:9998 ESPcmdPort=7777 esp

This prepares the subsequent execution of the ESP system (see below) once the socket server is running on the (simulated) vehicle.

On tethyssim:

$ bin/LRAUV -r -x "run Engineering/sample.xml"

Once the socket server is ready to accept the ESP connection, indicated by a line like so: 2015-10-28T16:12:36.161Z,1446048756.161 [ESPComponent](IMPORTANT): Waiting for ESP to connect (timeout=10.0000)

go to the bufflehead session and run:

$ ESPclient=tethyssim:9998 ESPcmdPort=7777 esp

which makes the ESP to connect as a TCP client to the vehicle at tethyssim:9998, and also launch a TCP server on port 7777 for subsequent connection of vehicle as TCP client.

Output on both terminals will show communication establishment and complete sampling. All messages received from the ESP are captured in Logs/latest/ESP.log.

References connectExec_, connectTimeoutCfgReader_, debugCfgReader_, espAlwaysServer_, espServerHostCfgReader_, filterCompleteTimeoutCfgReader_, filterResultTimeoutCfgReader_, initialPromptTimeoutCfgReader_, loadCartridgeTimeoutCfgReader_, loadControl_, Component::logger_, Component::newConfigReader(), Component::newDataWriter(), poTimeoutCfgReader_, pppFlow_, processCompleteTimeoutCfgReader_, processResultTimeoutCfgReader_, readConfigs(), Slate::ReadOnce(), sampleNumberWriter_, sampleTimeoutCfgReader_, samplingActiveWriter_, Component::setAllowableFailures(), Component::setFailureMissionCritical(), Component::setRetryTimeout(), Component::setRunState(), Component::simulateHardware(), socketServerPortCfgReader_, Component::STOP, stopResultTimeoutCfgReader_, and uartName_.

ESPComponent::~ESPComponent ( )
virtual

References espClient_, espComm_, and loadControl_.

ESPComponent::ESPComponent ( const ESPComponent old)
private

Member Function Documentation

void ESPComponent::createESPComm ( )
private

Creates espComm_ in specific mode (LRAUV either as server or client) depending on espServerHost_ (and using socketServerPort_ if LRAUV is to be server).

Also sets espAlwaysServer_ accordingly.

References StrValue::asString(), Str::cStr(), debug_, Syslog::ERROR, espAlwaysServer_, espComm_, espServerHost_, Syslog::FAULT, Str::length(), logDebug(), Component::logger_, ESPComm::setDebug(), socketServerPort_, and Logger::syslog().

Referenced by start(), and starting().

void ESPComponent::espReady ( )
private
ConfigURI ESPComponent::getConfigURI ( ConfigOption  configOption) const
virtual

Should return [myNamespace]::SIMULATE_HARDWARE, or [myNamespace]::POWER, etc.

Reimplemented from Component.

References Component::CONFIG_POWER, Component::CONFIG_SIMULATE_HARDWARE, and ConfigURI::NO_CONFIG_URI.

int ESPComponent::getLine ( Str line)
private

Expects next line from the ESP.

NOTE: This method is actually only called while in SS_WAITING_FOR_PORT_NUMBER. The getLine logic here is similar to that of the getLine method in ESPClient. This could be factored out at some point.

Parameters
linethe receive line is reported here. Trailing
NOT included.
Returns
+1: a line was actually received in this call 0: still waiting for line <0: some error (in readLine)

References FailureMode::COMMUNICATIONS, Str::cStr(), debug_, Timestamp::elapsed(), ESPComm::escape(), espComm_, Syslog::FAULT, Str::length(), lineTimeout_, logDebug(), Component::logger_, partialLine_, ESPComm::readLine(), Component::setFailure(), startTimeForLine_, and Logger::syslog().

Referenced by starting().

bool ESPComponent::getSimulatedData ( )
private
bool ESPComponent::isDataRequested ( )
private
bool ESPComponent::openServerSocket ( )
private

opens server socket to listen for ESP connection

References ESPComm::errorString(), espComm_, ESPComm::hasError(), Component::logger_, ESPComm::open(), and Logger::syslog().

Referenced by starting().

Component::RunState ESPComponent::pause ( )
virtual

Pause for a short period (indicated by pauseTime)

Reimplemented from Component.

References debug_, logDebug(), and Component::STOP.

Component::RunState ESPComponent::paused ( )
virtual

Should eventually follow a PAUSE request: should set continueTime.

Reimplemented from Component.

References debug_, logDebug(), and Component::STOP.

bool ESPComponent::powerDownESP ( bool  setFailure = true)
private

powers down ESP and brings down PPP link.

Parameters
setFailuretrue (the default) to report problem with powerDown call to loadControl as a FAULT and set failure to HARDWARE; otherwise, such problem is just reported as a DEBUG message.

References Syslog::FAULT, FailureMode::HARDWARE, Syslog::INFO, loadControl_, logDebug(), Component::logger_, LoadControl::powerDown(), Component::setFailure(), stopPPP(), and Logger::syslog().

Referenced by starting(), and stop().

bool ESPComponent::powerUpESP ( )
private
bool ESPComponent::readAdjustableConfigs ( )
private
virtual RunState ESPComponent::resetting ( )
inlinevirtual

Might occur in case of Error.

Reimplemented from Component.

References start().

Component::RunState ESPComponent::resume ( )
virtual

Resume from PAUSE.

Reimplemented from Component.

References debug_, logDebug(), and Component::START.

Component::RunState ESPComponent::resuming ( )
virtual

Might follow a PAUSE...RESUME sequence.

Reimplemented from Component.

References debug_, logDebug(), and Component::START.

void ESPComponent::run ( void  )
virtual

The actual "payload" of the component.

Reimplemented from Component.

bool ESPComponent::scanEspServerPort ( Str line,
int *  espServerPort 
)
private

Once the ESP is connected as a client, we expect a first line indicating the port it is listening on as a server.

This port, along with the peer address, is captured in case we need to connect as a client later on (specifically for the submitAbort operation).

References FailureMode::COMMUNICATIONS, Str::cStr(), debug_, Syslog::FAULT, logDebug(), Component::logger_, Component::setFailure(), and Logger::syslog().

Referenced by starting().

Component::RunState ESPComponent::start ( )
virtual

Do what needs to be done to run Similar to initialize, in old init/run/uninit sequence.

Creates espComm_ object, if not already created; and then transitions to STARTING.

Reimplemented from Component.

References ESPComm::close(), createESPComm(), debug_, espComm_, Syslog::FAULT, FailureMode::HARDWARE, isDataRequested(), ESPComm::isReadable(), logDebug(), Component::logger_, Component::setFailure(), Component::simulateHardware(), Component::START, Component::STARTING, Component::STOP, Component::STOPPED, and Logger::syslog().

Referenced by resetting().

const char* ESPComponent::startStateName ( StartState  startState)
inlineprivate
Component::RunState ESPComponent::stopped ( )
virtual

Initial state – can be later followed by START.

Reimplemented from Component.

References isDataRequested(), Component::START, and Component::STOPPED.

void ESPComponent::uninitialize ( void  )
virtual

Member Data Documentation

StrValue ESPComponent::connectExec_
private

Referenced by ESPComponent(), and startPPP().

Timespan ESPComponent::connectTimeout_
private

Referenced by readConfigs(), and starting().

ConfigReader* ESPComponent::connectTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

ConfigReader* ESPComponent::debugCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

bool ESPComponent::espAlwaysServer_
private

true if and only if espServerHost_ is non-empty and has the format "hostname:portNumber"

Referenced by createESPComm(), ESPComponent(), and stop().

ESPClient* ESPComponent::espClient_
private

High-level logic for interactions with the ESP.

Referenced by createESPClient(), runnable(), startSamplingPhase(), stop(), and ~ESPComponent().

ESPComm* ESPComponent::espComm_
private
StrValue ESPComponent::espServerHost_
private

Typically this will the empty string from configuration, meaning that the LRAUV will power-up and down the ESP as part of an overall sampling sequence.

If non-empty, must have the format "hostname:portNumber" (with portNumber > 0), indicating the host and port of the ESP server. In this case, the LRAUV will always assume the ESP is already running and accessible at hostname:portNumber. No ESP power cycling at all will be performed.

Referenced by createESPComm(), and readConfigs().

ConfigReader* ESPComponent::espServerHostCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Timespan ESPComponent::filterCompleteTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::filterCompleteTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Timespan ESPComponent::filterResultTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::filterResultTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Timespan ESPComponent::initialPromptTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::initialPromptTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Timespan ESPComponent::lineTimeout_
private

Referenced by getLine().

Timespan ESPComponent::loadCartridgeTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::loadCartridgeTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Str ESPComponent::partialLine_
private

Referenced by getLine().

Timespan ESPComponent::poTimeout_
private

Timeouts.

Referenced by readConfigs(), starting(), and waitForESPConnection().

ConfigReader* ESPComponent::poTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Str ESPComponent::pppCmd_
private

Referenced by startPPP().

StrValue ESPComponent::pppFlow_
private

Referenced by ESPComponent(), and startPPP().

Timespan ESPComponent::processCompleteTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::processCompleteTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

Timespan ESPComponent::processResultTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::processResultTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

int ESPComponent::sampleNumber_
private
DataWriter* ESPComponent::sampleNumberWriter_
private

Referenced by ESPComponent(), and writeData().

Timestamp ESPComponent::sampleTime_
private

Time when sampling started.

Referenced by getSimulatedData(), runnable(), startSamplingPhase(), and writeData().

Timespan ESPComponent::sampleTimeout_
private
ConfigReader* ESPComponent::sampleTimeoutCfgReader_
private
bool ESPComponent::samplingActive_
private
DataWriter* ESPComponent::samplingActiveWriter_
private
ESPClient::SamplingState ESPComponent::samplingState_
private

Referenced by runnable(), and startSamplingPhase().

int ESPComponent::socketServerPort_
private

Referenced by createESPComm(), and readConfigs().

ConfigReader* ESPComponent::socketServerPortCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

StartState ESPComponent::startState_
private

Referenced by starting(), and stop().

Timestamp ESPComponent::startTimeAccept_
private

Time prior to accept ESP client connection:

Referenced by starting(), and waitForESPConnection().

Timestamp ESPComponent::startTimeConnecting_
private

Time prior to connecting as client to the ESP:

Referenced by starting().

Timestamp ESPComponent::startTimeForLine_
private

Time prior to expecting a line from ESP:

Referenced by getLine(), and starting().

Timespan ESPComponent::stopResultTimeout_
private

Referenced by createESPClient(), and readConfigs().

ConfigReader* ESPComponent::stopResultTimeoutCfgReader_
private

Referenced by ESPComponent(), and readConfigs().

UartStream ESPComponent::uart_
private

Power and comms in this case.

Referenced by startPPP(), and stopPPP().

StrValue ESPComponent::uartName_
private

Referenced by ESPComponent(), and startPPP().


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