Debug Manual

Table Of Contents
Sample Debug Sessions
Debug Manual421921-003
F-14
TNS Program Example
Displaying Data Using Extended Address
The EXAMPLE_FILL_ARRAY procedure does not update the extended indirect pointer
SP located at the program’s global 12, so it is pointing to the beginning of the
selectable segment. We can repeat the A and D commands above, using SP as a
string extended address.
In this case, because the S indirection type indicates a string (byte), index is a byte
offset, which eliminates the need of dividing the address by 2. Instead of using the a q
#40/2, #10/2, c command in the above example, we can also enter it as: a
ud,12sx#40,#10/2,c.
The EXAMPLE_FILL_ARRAY procedure has a local extended string pointer,
SEGMENT_PTR, located at L 4. The pointer is set to offset 41 of SP. We can repeat
the A commands above, using SEGMENT_PTR.
We resume the program so that it stops the next time we reach the end of
EXAMPLE_FILL_ARRAY procedure. The ? command shows us which segment is in
use.
050,03,00013-d 12ix, c :h
%000000: 01 00
050,03,00013-a 12sx + #40, #10/2, c
%000024:.abcdefg..
Note. For the A command, we are using this address form:
offset [indirection-type [index]].
050,03,00013-a L4sx, #10/2, c
%000024:.abcdefg..
050,03,00013-r
enter some data
tuvwxyz
DEBUG P=%000174, E=%000207, UC.%00-BREAKPOINT-
050,03,00013-?
USE SEGMENT ID = %000002
BASE STANDARD IN
BASE STANDARD OUT
TERM \M5.$ZTN00.#PTAZJAC
PRV = OFF