reader now properly handles -128 in ground data. small modifications to the writer.