Breaking, Tracing, And Arming; The Example - Intel l2ICE User Manual

Integrated instrumentation and in-circuit emulation system
Table of Contents

Advertisement

Breaking, Tracing, and Arming

This section explains how to set breakpoints and how to control and interpret the trace buffer.

The Example

The sample program used in this section is an expansion of the program used in previous
section. This version first reads the amount tendered (paid) and the amount of the purchase
(purchase). The program then calculates the number of quarters, dimes, nickels, and pennies
needed and sends each result to a different I/O port. The list file produced by the PLM86
compiler is as follows:
Source File: CMAKER.SRC
Object File: CMAKER.OBJ
Controls Specified: XREF, DEBUG.
STMT
LINE
1
1
2
3
4
3
4
5
5
7
6
8
6
9
7
10
11
8
9
12
15
10
10
16
11
17
12
19
13
20
14
21
22
15
16
23
17
24
18
25
19
26
20
28
21
29
Introduction to Using the PICE™ System
NESTING
SOURCE TEXT: CMAKER.SRC
0
PROGRAM CMAKER;
0
VAR
0
0
0
0
0
0
0
PROCEDURE payment;
0
1 0
BEGIN
1
1
OUTWRD(70,quarters);
OUTWRD(72,dimes);
1
1
OUTWRD(74, nickels);
1
1
OUTWRD(76,pennies)
1
1
END;
BEGIN
0
0
0
1
INWRD(2,paid);
INWRD(4,purchase);
0
1
change
0
1
coins
1
0
quarters
0
1
coins
0
1
0
1
dimes
1
coins
0
0
1
nickels
1
pennies
0
1
0
payment;
1
END.
0
coins, change
quarters,nickels,dimes,pennies
paid, purchase
: =
paid — purchase;
: =
change MOD 100;
: =
coins DIV 25;
: =
coins MOD 25;
:=
coins DIV 10;
:=
coins MOD 10;
: =
coins DIV 5;
: =
coins MOD 5;
INTEGER;
INTEGER;
:WORD;
3-33

Advertisement

Table of Contents
loading

Table of Contents