added debug code to socket so that I can see what's being sent real time
and make sure everything is responding correctly