Added write path and simple terminal interface