hex2file

hex2file is a portable tool to convert Intel HEX format compatible files into custom file formats and it also display the HEX file contents in different views.

Usage:

hex2file <input hex file> <output file> [format specifier]

<input hex file> is an exisiting intel HEX format compatiable file.

set <output file> to "screen" to print all the contents into standard output (which is most probably text terminal which initiated the hex2file program) or specify some filename to write output into that file.

Format Specifiers is an optional parameter and default is set to (-b) binary mode.

Examples:

Print content of sample.hex file in hexadecimal view:

hex2file sample.hex screen


0xAC 0x12 0xAD 0x13 	0xAE 0x10 0xAF 0x11 
0x12 0x00 0x2F 0x8E 	0x0E 0x8F 0x0F 0x22 
0xE5 0x0B 0x25 0x0D 	0xF5 0x09 0xE5 0x0A 
0x35 0x0C 0xF5 0x08 	0x12 0x00 0x13 0x22 
0x02 0x00 0x23 0x78 	0x7F 0xE4 0xF6 0xD8 
0xFD 0x75 0x81 0x13 	0x02 0x00 0x03 0xEF 
0xF8 0x8D 0xF0 0xA4 	0xFF 0xED 0xC5 0xF0 
0xCE 0xA4 0x2E 0xFE 	0xEC 0x88 0xF0 0xA4 
0x2E 0xFE 0x22 0x00

Print content of sample.hex file in 8bit binary mode:

hex2file sample.hex screen -8


00110101 01001000 10110101 11001000 	01110101 00001000 11110101 10001000 
01001000 00000000 11110100 01110001 	01110000 11110001 11110000 01000100 
10100111 11010000 10100100 10110000 	10101111 10010000 10100111 01010000 
10101100 00110000 10101111 00010000 	01001000 00000000 11001000 01000100 
01000000 00000000 11000100 00011110 	11111110 00100111 01101111 00011011 
10111111 10101110 10000001 11001000 	01000000 00000000 11000000 11110111 
00011111 10110001 00001111 00100101 	11111111 10110111 10100011 00001111 
01110011 00100101 01110100 01111111 	00110111 00010001 00001111 00100101 
01110100 01111111 01000100

Save content of sample.hex file into CSV file:

hex2file sample.hex output_file.csv -c

Download:

hex2file is available to download for both Linux and Windows operating systems. To obtain latest version of hex2file binaries, check the files section of hex2file – sourceforge.net page.

hex2file is an open source free software project and it’s complete source code is available to download at hex2file SVN repository at sourceforge.net. This project is written using FPC/Lazarus and current version is compiled using Lazarus 0.9.30.2 and FPC 2.4.4.

License:

This program is free software, you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.


Copyright © 2013 Dilshan R Jayakody.