Complete overhaul of codec with new and improved socket interface
Added generated unit test