reworking touch server connection code