Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 8

mkrec

Convert a binary image into ROM format (QNX)

Syntax:

mkrec [option | imagefilename] …

Runs on:

QNX Neutrino, Linux, Microsoft Windows

Options:

-a align[K|M|G]
Force the next file to be aligned on an align-byte boundary (the default is 1 byte).
-f format
Output format:

The default is srec. When using binary, the file's offset is printed to stderr.

-l reclen
(“el”) Length of data bytes per line (the default is 32).
-o offset
The offset, in hexadecimal (the default is 0).
-r
Suppress the reset vector record.
-s romsize[K|M|G]
Size of ROM (the default is 4G). The case of the suffixes doesn't matter.

Description:

The mkrec utility converts a binary image into either Motorola S records or Intel hex records, which are suitable input for most Flash/EPROM programmers. Most ICEs also expect these formats. The format defaults to Motorola S records but may be changed using the -f format option. Note that the Intel format is limited to 1M offsets.

By default, mkrec assumes the image contains code that is the initial program loader (IPL), which is connected to the power-on reset vector of the processor. The mkrec utility locates the image such that it's placed in the address space where it will end at the reset vector. A record is then output for the reset vector, which will do a 16-bit relative jmp to the start of the image.

The reset vector on an Intel 386/486/... processor is located at linear address 0xFFFFFFF0 (16 bytes below 4 Gigabytes). The offsets used for the records by default address this area. It's as though you had a 4-Gigabyte ROM and needed to load code into the top of it. This is what most ICEs expect. If you're sending your output to a small Flash/EPROM programmer, it may wish the offsets to be relocated to the top of the the Flash/EPROM alone. You can do this by using the -s size option.

If the -r option is set, it indicates that the image shouldn't be considered a power-on IPL. The record offsets for the image start at zero; a jmp isn't be programmed at the top of the device. You can use the -o option to change the record offset. Note that you can use the -o option only if you use -r.

For compatibility with most devices that accept these records, each record is limited to a maximum of 32 bytes. You can use the -l option to increase this limit to a maximum of 255 bytes. Larger records have less overhead and result in slightly faster downloads.

Examples:

The following converts the binary image explr2 into Motorola S records. The offset used in the records starts the image such that it ends at the reset vector 0xFFFFFFF0. A 16-bit relative jmp is programmed at 0xFFFFFFF0 to jmp to the start of the image.

mkrec explr2

The following converts the binary image ipl into Intel hex records. The offset used in the records starts the image such that it ends at the reset vector in the 256K ROM (0x3FFF0). A 16-bit relative jmp is programmed at 0x3FFF0 to jmp to the start of the image.

mkrec -f i -s 256k ipl

The following converts the binary image notipl into Motorola S records. The offset used in the records starts at 0; a reset vector jmp isn't output.

mkrec -r notipl

See also:

mkefs, mkifs


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 213

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/m/mkrec.html on line 213