UserInterface Class Reference

#include <ui.h>

Inheritance diagram for UserInterface:
Inheritance graph
[legend]
Collaboration diagram for UserInterface:
Collaboration graph
[legend]

List of all members.

Public Member Functions

void AddExternalType (const char *name, ExternalType *p)
void AddExternalType (const std::string &name, ExternalType *p)
 UserInterface (int port, bool withUpdateControl=true)
 ~UserInterface ()
void SendUiNewState (const std::string &s, const char &c)
int Step (bool &, SystemClockOffset *nextStepIn_ns=0)
 Return nonzero if a breakpoint was hit.
void SwitchUpdateOnOff (bool PollFreq)
void Write (const std::string &s)

Protected Member Functions

void SetNewValueFromUi (const std::string &)

Protected Attributes

std::map< std::string,
ExternalType * > 
extMembers
bool updateOn
SystemClockOffset pollFreq
std::string dummy
std::map< std::string, char > LastState
int waitOnAckFromTclRequest
int waitOnAckFromTclDone

Detailed Description

Interfacing between "UI" application on TCP port and ExternalType objects which interface with device peripherals.

Definition at line 41 of file ui.h.


Constructor & Destructor Documentation

UserInterface::UserInterface ( int  port,
bool  withUpdateControl = true 
)

Definition at line 37 of file ui.cpp.

References AddExternalType(), waitOnAckFromTclDone, waitOnAckFromTclRequest, and Write().

Here is the call graph for this function:

UserInterface::~UserInterface (  ) 

Definition at line 48 of file ui.cpp.


Member Function Documentation

void UserInterface::AddExternalType ( const std::string &  name,
ExternalType p 
) [inline]

Definition at line 58 of file ui.h.

References AddExternalType().

Here is the call graph for this function:

void UserInterface::AddExternalType ( const char *  name,
ExternalType p 
) [inline]

Definition at line 54 of file ui.h.

References extMembers.

Referenced by AddExternalType(), ExtAnalogPin::ExtAnalogPin(), ExtPin::ExtPin(), Keyboard::Keyboard(), SerialRx::SerialRx(), SerialTx::SerialTx(), and UserInterface().

Here is the caller graph for this function:

void UserInterface::SendUiNewState ( const std::string &  s,
const char &  c 
)

Definition at line 129 of file ui.cpp.

References LastState, and Write().

Referenced by ExtAnalogPin::SetInState(), and ExtPin::SetInState().

Here is the call graph for this function:

Here is the caller graph for this function:

void UserInterface::SetNewValueFromUi ( const std::string &  value  )  [protected, virtual]

Implements ExternalType.

Definition at line 144 of file ui.cpp.

References updateOn.

Referenced by Step().

Here is the caller graph for this function:

int UserInterface::Step ( bool &  trueHwStep,
SystemClockOffset timeToNextStepIn_ns = 0 
) [virtual]

Return nonzero if a breakpoint was hit.

Implements SimulationMember.

Definition at line 56 of file ui.cpp.

References avr_error, dummy, extMembers, Socket::Poll(), pollFreq, Socket::Read(), SetNewValueFromUi(), updateOn, waitOnAckFromTclDone, and waitOnAckFromTclRequest.

Here is the call graph for this function:

void UserInterface::SwitchUpdateOnOff ( bool  PollFreq  ) 

Definition at line 51 of file ui.cpp.

References updateOn.

void UserInterface::Write ( const std::string &  s  ) 

Member Data Documentation

std::string UserInterface::dummy [protected]

Definition at line 46 of file ui.h.

Referenced by Step().

std::map<std::string, ExternalType*> UserInterface::extMembers [protected]

Definition at line 43 of file ui.h.

Referenced by AddExternalType(), and Step().

std::map<std::string, char> UserInterface::LastState [protected]

Definition at line 47 of file ui.h.

Referenced by SendUiNewState().

Definition at line 45 of file ui.h.

Referenced by Step().

bool UserInterface::updateOn [protected]

Definition at line 44 of file ui.h.

Referenced by SetNewValueFromUi(), Step(), SwitchUpdateOnOff(), and Write().

Definition at line 49 of file ui.h.

Referenced by Step(), and UserInterface().

Definition at line 48 of file ui.h.

Referenced by Step(), UserInterface(), and Write().


The documentation for this class was generated from the following files:
Generated on Sun Feb 12 16:53:27 2012 for Simulavr by  doxygen 1.6.3