FileOutputStream replaced by PrintWriter.
Improve of measurement cycle.