User`s guide

VxWorks
BSP Developer’s Guide, 6.0
118
Finding Code Block Addresses
You can use objdumparch when you need to find the code that resides at a
particular RAM address. For example, the following command shows the entire
contents of a vxWorks image file:
objdumpppc --disassemble-all --show-raw-insn vxWorks
Finding Addresses in the Flash image
A common problem with the development environment is that the process of
programming the image into flash does not put the data at the correct location. One
way to test this is to examine the hex file—that is, bootrom.hex or
vxWorks_rom.hex, and the contents of memory, to insure that they match as
expected.
Hex files are usually used in the process of creating a flash image or burning the
image to ROM. If the process being used to create and burn the flash image does
not involve a hex file, skip the remainder of this section.
The following is the extra build output generated when creating bootrom.hex.
Notice that the utility used to perform the conversion from ELF to hex is
objcopyarch.
C:\T22\ppc\host\x86-win32\bin\objcopyppc -O srec \
--gap-fill=0 bootrom out.tmp1
C:\T22\ppc\host\x86-win32\bin\objcopyppc -O srec \
--ignore-vma --set-start=0x0 out.tmp1
This hex file is really a Motorola S-Record file that is assumed to start at address 0.
Using your flash programmer, you must perform whatever bias or offset is
required so that this file will start at the reset vector. Consult your flash
programmer documentation for specific details.
The following example shows some data from a bootrom.hex file:
S00E0000626F6F74726F6D2E6865787C
S21400000048000039600000004800003D436F7079EA
S214000010726967687420313938342D3230303120B7
NOTE: When using the Wind River ICE tools to perform the flash programming,
the conversion is from a hex file to a bin file. The bin file that the Wind River tools
generate is a special format specific to the Wind River ICE tools and is not the more
commonly recognized bin format. Therefore, use caution when sharing bin files
between Wind River ICE tools and other flash programmers, the formats are not
likely to be compatible.