
Hitachi Embedded Workshop User Manual
186
Figure 4.5 Assembler Dialog Box
The address, machine code, and disassembled instruction are displayed. Enter the new instruction or edit the old
instruction in the [Mnemonics] field. Pressing the Enter key will assemble the instruction into memory and move
on to the next instruction. Clicking the [OK] button will assemble the instruction into memory and close the
dialog box. Clicking the [Cancel] button or pressing the Esc key will close the dialog box.
Note: The assembly-language display is disassembled from the actual machine code in the debugging
platform's memory. If the memory contents are changed the dialog box (and [Disassembly]
window) will show the new assembly-language code, but the [Source] window contents will be
unchanged. This is the same even if the source file contains an assembler.
4.1.6
Viewing a Specific Address
When you are viewing your program in the [Disassembly] window, you may wish to look at another area of your
program's code. Rather than scrolling through a lot of code in the program, you can go directly to a specific
address. Select [Set Address] from the pop-up menu, and the dialog box shown in figure 4.6 is displayed.
Figure 4.6 Set Address Dialog Box
Enter the address or label name in the edit box and either click on the [OK] button or press the Enter key. The
[Disassembly] window will be updated to show the code at the new address. When an overloaded function or a
class name is entered, the [Select Function] dialog box opens for you to select a function. For details, refer to
section 4.10, Elf/Dwarf2 Support.
4.1.7
Viewing the Current Program Counter Address
Wherever you can enter an address or value into the HEW, you can also enter an expression. If you enter a
register name prefixed by the hash character, the contents of that register will be used as the value in the
expression. Therefore, if you open the [Set Address] dialog box and enter the expression #pc, the [Source] or
[Disassembly] window will display the current PC address. It also allows the offset of the current PC to be
displayed by entering an expression with the PC register plus an offset, e.g., #PC+0x100.
4.2
Operating Memory
This section describes how to look at memory areas in the CPU's address space. How to look at a memory area
in different formats, how to fill and move a memory block, and how to load and verify a memory area with a
disk file are described.