Initial implementations of send() and input reading.