Protected Member Functions | Protected Attributes | Private Attributes
FakeSerial Class Reference

List of all members.

Protected Member Functions

virtual void SetUp ()
virtual void TearDown ()
void write_serial (const std::string &msg)

Protected Attributes

serial::Serial ser

Private Attributes

int master_fd
char * ser_name

Detailed Description

Definition at line 7 of file test_comms.cpp.


Member Function Documentation

virtual void FakeSerial::SetUp ( ) [inline, protected, virtual]

What's going on here? The posix_openpt() call establishes a pseudo terminal and gives us a fd for the other end of it. So we can connect up a Serial instance to the pty, and have full control over reading-from and writing-to the driver.

Definition at line 16 of file test_comms.cpp.

virtual void FakeSerial::TearDown ( ) [inline, protected, virtual]

Definition at line 32 of file test_comms.cpp.

void FakeSerial::write_serial ( const std::string &  msg) [inline, protected]

Definition at line 27 of file test_comms.cpp.


Member Data Documentation

int FakeSerial::master_fd [private]

Definition at line 41 of file test_comms.cpp.

serial::Serial FakeSerial::ser [protected]

Definition at line 38 of file test_comms.cpp.

char* FakeSerial::ser_name [private]

Definition at line 42 of file test_comms.cpp.


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


um6
Author(s): Mike Purvis
autogenerated on Thu Aug 27 2015 15:31:34