import ClientClass import DBC from time import sleep #MAIN PART user = 'root' passw = 'mysqlpassword' host = 'localhost' dbname = 'gsmselftesting' database = DBC.DBMySQLConnection(user, passw, host, dbname) x = ClientClass.Connection('localhost',50008) print x.connect() x.sendData('HELLO HANDLER') print x.receiveData() x.sendData('CALLER|NUMBER') print x.receiveData() sleep(4) print 'sta sam dobio' x.sendData('RECEIV|READY') print x.receiveData() x.sendData('TERMINATE') print x.receiveData() x.closeConnection()