Implement socket

Next: implement piece moves