Add preliminary command reading and writing