error on reading binary data

From: <tingting_at_nyahnyahspammersnyahnyah>
Date: Fri Jan 25 2013 - 13:56:54 MST

Hi all,
I have one question on reading a binary data, the format of binary data:
One-byte (scaled, unsigned integer) flat binary arrays preceded by a
300-byte header, no byte order/endianness.
Part of my script:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  fin = "./conc/nt_200801_f17_v01_n.bin"
;--read header--;
  head = fbindirread(fin, 0, 300, "character")
  ;print(head)
  ;exit
;---read data--;
   bdata = fbindirread(fin,0,(/ NY,MX /),"byte")
   data = byte2flt(bdata)
   printMinMax(data, True)
   ...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Then, the output shows the range: -127~128. While, in data document, the
range is 0~255. Will be something wrong in my script?
Thanks a lot in advance!
Tingting

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Jan 25 13:57:03 2013

This archive was generated by hypermail 2.1.8 : Tue Jan 29 2013 - 22:44:26 MST