How to Read 2 byte data from the binary file using the linux command for e=windows machine?

22 Views Asked by At

I would like to know the command equivalent to: od −v −t u2 −w4 −An datafile.data | ./datafile for windows machine. here ./datafile is fortran compiled o/p using the following command gfortran datafile.f -o datafile

Get-Content -Raw -Encoding Byte "datafile.data" | ForEach-Object { "{0:D5}" -f [BitConverter]::ToUInt16($_, 0) } | Out-File -Encoding ASCII -FilePath "output.txt

But, it thorws error

0

There are 0 best solutions below