I try to read some binary data, but I failed.
The binary file “dump.bin” first contains two 4-BYTE integers NX and
NY and then a grid of NXNY REAL4 samples.
In my case NX=69 (=45 HEX) and NY=81 (=51 HEX).
When I put the binary file in my HEX-editor, I get a first line of:
45 00 00 00 51 00 00 00 00 00 00 00 00 00 00 00
Recognize the NX and NY values in HEX!
The file contains rain data, and often it doesn’t rain.
Indeed the first few samples after NX and NY are zero.
Then I tried to make an ASCII dump of dump.bin by running the
executable made with pgf90 from:
INTEGER(4) :: i,NX,NY,NxNy
REAL(4) :: Dum
WRITE(,) Nx,’ ',Ny
NxNy = NXNY
All I got was a message:
PGFIO-F-201/OPEN/unit=13/illegal value for specifier.
File name = dump.bin
In source file readbinny.f90, at line number 4
At home, where I don’t have a pc with Portland F90 license, I had a similar problem under g95. There it was solved by adding ACCESS=‘STREAM’ in the open statement.
How to proceed from here with pgf90?