Break Setup Commands; Break (Set Software Pc Break); Tbreak (Set Temporary Software Pc Break) [Icd Mini / Sim] - Epson S5U1C17001C Manual

Cmos 16-bit single chip microcontroller (c compiler package for s1c17 family) (ver. 3.1)
Hide thumbs Also See for S5U1C17001C:
Table of Contents

Advertisement

8.5.9

Break Setup Commands

break
(set software PC break)
tbreak
(set temporary software PC break)
Operation
Sets a software PC breakpoint. Up to 200 software PC breakpoints can be set. However, if breakpoints are set on the ROM on
the target board in ICD Mini mode, this command functions in the same way as the hbreak/thbreak command and sets
hardware PC breakpoints.
If the PC matches the address set during program execution, the program breaks before executing the instruction at that address.
A breakpoint can be set using a function name, line number, or address.
The break and tbreak commands are functionally the same. The following describes the difference:
break: The breakpoints set by break are not cleared by a break that occurs when the set point is reached during program
execution.
tbreak: The breakpoints set by tbreak are cleared by one occurrence of a break at the set point.
Format
break [Breakpoint]
tbreak [Breakpoint]
Breakpoint: Breakpoint
A breakpoint can be specified with one of the following:
• Function name
• Source file name:line number or line number only
• *Address (decimal, hexadecimal, or symbol)
When omitted, a breakpoint is set at the address displayed on the current PC.
Conditions: 0 ≤ address ≤ 0xfffffe
Usage example
■Example 1
(gdb) break main
Breakpoint 1 at 0xc0001e: file main.c, line 10.
(gdb) continue
Continuing.
Breakpoint 1, main () at main.c:10
A software PC breakpoint is set at the position specified using a function name.
When the target program is run, it breaks before executing the first C instruction (expanded to mnemonic) in main(). The PC
on which the program has stopped displays the start address of that instruction (i.e., address of first mnemonic expanded).
■Example 2
(gdb) tbreak main.c:10
Breakpoint 1 at 0xc0001e: file main.c, line 10.
A temporary software PC breakpoint is set at the position specified with a line number. Although the breakpoint here is
specified in "source file name:line number" format when the breakpoint is to be set in the C source containing the current PC
address, it can be specified by simply using a line number like "tbreak 10". For assembly sources, a source file name is
always required.
If no instructions exist on the specified line with actual code (i.e., not expanded to mnemonic), a breakpoint is set at the
beginning of the first instruction encountered with actual code thereafter.
When the target program is run, it breaks before executing the C instruction on line 10 in main.c. The PC on which the
program has stopped displays the start address of that instruction (i.e., address of first mnemonic expanded). If no instructions
exist on line 10 with actual code, the program breaks at the beginning of the first instruction encountered with actual code
thereafter. Because the breakpoint is set by tbreak, it is cleared after a break.
S5U1C17001C Manual
(Rev. 1.0)
Seiko Epson Corporation
8 Debugger
[ICD Mini / SIM]
8-31

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the S5U1C17001C and is the answer not in the manual?

Table of Contents