Functions | Variables
oculusprimesocket Namespace Reference

Functions

def clearIncoming ()
 
def connect ()
 
def replyBufferSearch (pattern)
 
def sendString (s)
 
def waitForConnect ()
 
def waitForReplySearch (pattern)
 

Variables

bool connected = False
 
string host = "127.0.0.1"
 
int port = 4444
 
bool reconnect = False
 
 sock = None
 
 sockfileIO = None
 

Function Documentation

def oculusprimesocket.clearIncoming ( )
Clear socket buffer of all incoming server messages

Definition at line 66 of file oculusprimesocket.py.

def oculusprimesocket.connect ( )
Make socket connection to server, blocking

returns: True if success, False otherwise

Definition at line 103 of file oculusprimesocket.py.

def oculusprimesocket.replyBufferSearch (   pattern)
Search through unread output from server, compare to pattern, return match
stops reading buffer if finds a match

pattern -- regular expression pattern to be searched
returns: first line containing match, or empty string if search fails
non blocking function

Definition at line 79 of file oculusprimesocket.py.

def oculusprimesocket.sendString (   s)
Send single line command to server

s -- command to be sent

Definition at line 20 of file oculusprimesocket.py.

def oculusprimesocket.waitForConnect ( )

Definition at line 128 of file oculusprimesocket.py.

def oculusprimesocket.waitForReplySearch (   pattern)
Read all incoming messages from server, do not return until search match 

pattern -- regular expression pattern to be searched
returns first line containing match, or empty string if server shutdown
blocking function

Definition at line 36 of file oculusprimesocket.py.

Variable Documentation

bool oculusprimesocket.connected = False

Definition at line 13 of file oculusprimesocket.py.

string oculusprimesocket.host = "127.0.0.1"

Definition at line 10 of file oculusprimesocket.py.

int oculusprimesocket.port = 4444

Definition at line 11 of file oculusprimesocket.py.

bool oculusprimesocket.reconnect = False

Definition at line 14 of file oculusprimesocket.py.

oculusprimesocket.sock = None

Definition at line 16 of file oculusprimesocket.py.

oculusprimesocket.sockfileIO = None

Definition at line 17 of file oculusprimesocket.py.



oculusprime
Author(s): Colin Adamson
autogenerated on Wed Mar 10 2021 03:14:59