Relacs  0.9.8
bin2dat

bin2dat can be used to convert binary data as they are produced by RELACS, and especially the IOData::writeBinary() functions, into ascii data files.

USAGE

bin2dat <binfile> <datfile> <options>

The first argument <binfile> is the full specification of the file containing the binary data. The second argument is the output file in which the ascii data are written. The program tries to guess the data type of the binary file from its extension. See IOData::binaryExtension() about the standrd extension. The data type as well as the range of data can be specified by several options.

OPTIONS

EXAMPLES

To convert the whole binary file data.sw1 into the ascii file signal.dat use

bin2dat data.sw1 signal.dat

To convert only data elements 5 to 10 use

bin2dat data.sw1 signal.dat -O 5 -U 10

Data element 5 of a sw1 -file (signed word) is at byte offset 10. Data element 10 at 20. So, alternatively

bin2dat data.sw1 signal.dat -o 10 -u 20

can be used.

Write the first 100 bytes:

bin2dat data.sw1 signal.dat -n 100

Write 50 data elements starting at data element 20:

bin2dat data.sw1 signal.dat -O 20 -N 50

Write data elements 14 to 43 and add a time column with time step 0.1:

bin2dat data.sw1 signal.dat -O 14 -U 43 -t 0.1

Convert binary data file data.dat, which contains signed word (two bytes long) data of three multiplexed channels into ascii-file signal.dat:

bin2dat data.dat signal.dat -s 1 -d 2 -c 3