figuring out initial socket code