updated main init
added sys.io.stream.read, sys.io.stream.write