SerialPort Class Reference

List of all members.

Detailed Description

Definition at line 12 of file SerialPort.H.

Public Member Functions

 SerialPort (const std::string &filename, const int speed, const mode_t mode=O_RDWR|O_NONBLOCK)
 ~SerialPort ()
 operator int () const
bool fail () const
int setBaudRate (const int speed) const
int baudRate () const

Private Member Functions

 SerialPort (const SerialPort &port)
SerialPortoperator= (const SerialPort &port)

Static Private Member Functions

static int rate (speed_t baud)
static speed_t baud (const int speed)

Private Attributes

std::string m_filename
int m_fd
int m_speed


Constructor & Destructor Documentation

SerialPort ( const std::string &  filename,
const int  speed,
const mode_t  mode = O_RDWR|O_NONBLOCK 
)

Definition at line 30 of file SerialPort.cpp.

References m_fd, and setBaudRate().

~SerialPort (  ) 

Definition at line 68 of file SerialPort.cpp.

References m_fd.

SerialPort ( const SerialPort port  )  [private]


Member Function Documentation

operator int (  )  const [inline]

Definition at line 17 of file SerialPort.H.

References m_fd.

bool fail (  )  const [inline]

Definition at line 19 of file SerialPort.H.

References m_fd.

Referenced by RFlex::writePacket().

int setBaudRate ( const int  speed  )  const

Definition at line 74 of file SerialPort.cpp.

References baud(), baudRate(), m_fd, m_filename, and rate().

Referenced by SerialPort().

int baudRate (  )  const

Definition at line 106 of file SerialPort.cpp.

References m_fd, m_filename, and rate().

Referenced by setBaudRate().

int rate ( speed_t  baud  )  [static, private]

Definition at line 128 of file SerialPort.cpp.

References g_baud_rates, g_num_rates, and g_speeds.

Referenced by baudRate(), and setBaudRate().

speed_t baud ( const int  speed  )  [static, private]

Definition at line 138 of file SerialPort.cpp.

References g_baud_rates, g_num_rates, and g_speeds.

Referenced by setBaudRate().

SerialPort& operator= ( const SerialPort port  )  [private]


Member Data Documentation

std::string m_filename [private]

Definition at line 25 of file SerialPort.H.

Referenced by baudRate(), and setBaudRate().

int m_fd [private]

Definition at line 26 of file SerialPort.H.

Referenced by baudRate(), fail(), operator int(), SerialPort(), setBaudRate(), and ~SerialPort().

int m_speed [private]

Definition at line 27 of file SerialPort.H.


The documentation for this class was generated from the following files:
Generated on Thu Feb 1 15:31:55 2007 for WURDE by  doxygen 1.5.1