port::Port Class Reference
List of all members.
Detailed Description
Common base class for DataPort and ControlPort. Provides functionality to
recv/send Applanix-formatted packets from the socket. Could in future
support LoggingPort and DisplayPort.
Definition at line 55 of file port.py.
Member Function Documentation
def port::Port::__init__ |
( |
|
self, |
|
|
|
sock, |
|
|
|
opts | |
|
) |
| | |
def port::Port::_checksum |
( |
|
cls, |
|
|
|
buff | |
|
) |
| | [private] |
Compute Applanix checksum. Expects a StringIO with a
size that is a multiple of four bytes.
Definition at line 142 of file port.py.
def port::Port::recv |
( |
|
self, |
|
|
|
d = False | |
|
) |
| | |
Receive a packet from the port's socket.
Returns (pkt_id, pkt_str), where pkt_id is ("$GRP"|"$MSG", num)
Returns None, None when no data.
Definition at line 72 of file port.py.
def port::Port::send |
( |
|
self, |
|
|
|
header, |
|
|
|
message | |
|
) |
| | |
Sends a header/msg/footer out the socket. Takes care of computing
length field for header and checksum field for footer.
Definition at line 109 of file port.py.
Member Data Documentation
The documentation for this class was generated from the following file: