It is difficult for an application to control sending individual packets over TCP. The server could be using UDP, which does use single packets, or it could be using a protocol with messages over a TCP stream. With the TCP server, use the low-level sysread/syswrite to make sure that you don't block waiting for data.