© 2000, The TRAC Foundation
Chapter 1: Introduction to TRAC
1.6.1 Format of Primitive Statements
1.9.1 Starting Interactive Mode in the Dialer
Chapter 2: Primary Primitives
2.2 Primary Primitive Reference
Chapter 3
Arithmetic Primitives
3.1 Introduction to the Arithmetic Primitives
3.2 Arithmetic Primitives Reference
as - Integer Add
ag - Greater Than Test
am - Integer Multiply
aq - Integer Quotient
ar - Integer Remainder
as - Integer Subtract
Chapter 4
Bit Manipulation and Display Primitives
4.1 Introduction to the Bit Manipulation Primitives
4.2 Bit Manipulation Primitives Reference
bbo - Binary to Octet
bla - AND
bln - Negation or Complement
blo - OR
blx - eXclusive OR
bob - Octet to Binary
bon - Octet to Decimal
box - Octet to Hex
bxo - Convert Hexadecimal to ASCII
Chapter 5
File Primitives
5.1 Introduction to the File Primitives
5.1.1 File Group
5.1.2 File Position Group
5.2 File Primitive Reference
fc - File Close
fe - File Erase
fg - Generate New File
fo - File Open
fpb - Position from Beginning
fpc - Position from Current
fpe - Position from End .
fpr - Position Read
fr - File Read
fs - File Status
fw - File Write
Chapter 6
Extended Input and Communication Primitives
6.1 Introduction to the Extended Input and Communication Primitives
6.2 Extended Input and Communication Primitive Reference
ia2 - Get or Set Com Port
ib2 - Get or Set Channel Baud Rate
is - Get or Set Input Meta Characters
ie - Input Echo
if - Input Echo Off
im - Monitor On
in - Monitor Off
ip - Pure Input
iq - Qualified Input
is -1/O Status
it - Transfer Control
iu - Restore Control
iv - Display Version
iw-Wait
iy - Determine if Input Is Available
iz - Zero Input Buffer
Chapter 7
Memory Primitives
7.1 Introduction to the Memory Primitives
7.1.1 Macro Memory Primitives
7.1.2 Memory Rearrangement Primitives
7.1.3 Memory Display Primitives
7.1.4 Memory Put and Fetch Primitives
7.1.5 Miscellaneous Memory Primitives
7.2 Memory Primitive Reference
ma - Delete All
me - Erase File on Disk
mf - Fetch Form
mg - Gather Forms
mh - Form Is Here
ml - List Names
mlf - Turn Off Form Prefix
mlo - Turn On Form Prefix
mm - Make Macro
mn - Rename Form
mp - Memory Put
ms - String to Twiddle
mt - Memory Tree
my - Binary to Twiddle
mw - Twiddle to Binary
mx - Explode Node
Chapter 8
Network Primitives
8.1 Introduction to the Network Primitives
8.2 Principles of Operation
8.3 Establishing a Connection
8.4 Network Primitive Reference
na - Accept a Connection
nb - Test for buffer
nc - Close Socket
nh - Network Host
nk - Test for Connect
nm - Test for Message
nn - Initiate a Client Connection
np - Create a Responder Socket
nr - Receive a Message
ns - Send a Message
nt - Terminate Dialog
nv - Network Version
nvf - Network Diagnostics Off
nvo - Network Diagnostics On
nw - Net What
nwv - Value String for What
Chapter 9
Partition Primitives
9.1 Introduction to the Partition Primitives
9.1.1 Partition Group Primitives
9.1.2 Task and Shell Primitives.
9.2 Partition Primitive Reference
pc - Create Partition
pn - Read or Reset Auxiliary Index
pr - Read or Reset Partition Index
ps - Command To Shell
pt - Start New Task
px - Exit Partition
Chapter 10
Text Primitives
10.1 Introduction to the Text Primitives
10.1.1 General Text Primitives
10.1.2 Replace Text Primitives
10.1.3 Text Numerical Pointer Primitives
10.1.4 ASCII Text Conversion Primitives
10.2 Text Primitive Reference
to - ASCII Sequence
tca - Convert Numeric to ASCII
tcn - Convert ASCII to Numeric
tl - Length of Form
to - Copy a Number of Characters
tpb - Read from Beginning
tpe - Read to End
tpr - Text Pointer Read
tps - Text Pointer Set
tra - Replace All
trf - Replace First.
is - Segment Copy
tt - Text Inclusion Test
ttc - Case-insensitive Text Inclusion Test
Chapter 11
Dialer Primitives
11.1 Introduction to the Dialer Primitives
11.2 Dialer Primitive Reference.
wdial_changemode - Change Mode
wdial_identity - Get or Set PAP Userid or CHAP Identity
wdial_ipaddress - Get or Set IP Address
wdial_message - Display Message
wdial_modem - Get a Modem String
wdial_parity - Get or Set Parity
wdial_passcode-Get or Set Password
wdial_pause - Pause
wdial_phone - Get or Set Phone Number
wdial_poll - Poll Connection
wdial_prompt - Prompt for Response
wdial_secret - Get or Set PAP Password or CHAP Secret
wdial_username - Get or Set Username
Chapter 12
VVTNVT Telnet Primitives
12.1 WTNVT Telnet Primitive Reference
wtn_connect - Connect to Session
wtn_disconnect - Disconnect Current Session
wtn_message - Display Message
wtn_passcode - Get or Set Password
wtn_pause - Pause
wtn_prompt - Prompt for Response
wtn_receive - Receive Data from Host
wtn_sendkeys - Send VT Emulator Text and Keys
wtn_username - Get or Set Username
Chapter 13
Date, Time, and Diagnostic Primitives
13.1 Date and Time Primitives
13.2 Diagnostic Primitives
13.3 Date, Time, and Diagnostic Primitive Reference
xa - Diagnostic A
xb - Diagnostic B
xcc - Calendar Date
xcf - Formatted Date and Time
xcl - Long Time
xcm - Elapsed Milliseconds
xcs - Elapsed Seconds
xct - Time
xs - Status of Workspace
xtf - Trace Off
xto - Trace On
Appendix A
Quick Reference List for TRAC Primitives
Appendix B
Differences Between TR2 and TRAC
B.1 Differences in Primitives
B.1.1 TRAC Primitives not in TR2
B.1.2 TRAC Primitives Implemented Differently in TR2
B.2 Bugs
Appendix C
The TRAC Processor
C.1 Introduction to the TRAC Processor
C.2 Fundamentals
C.3 The Guiding Principle
C.4 The Five Meanings of Primitive
C.5 The Two Aspects: Language and Machine
C.5.1 The Language Aspect
C.5.2 The Machine Aspect of TRAC
C.6 The TRAC Interpreter
C.7 TRAC Syntax Characters
C.8 The Simplest Case, No Nested Primitives
C.9 The Case Of Nested Primitive Statements
C.10 The Case of the i Suffix
C.11 The Case of the d Suffix
C.12 The Z-Return Argument
C.13 Protective Parentheses
C.13.1 Commas
C.13.2 White Space and Control Characters
C.14 The TRAC Memory System
C.15 The Rules of TRAC Interpretation
Appendix D
TRAC Tutorial
D.1 Introducing TRAC
D.1.1 Simple Scripts
D.1.2 Conclusions
D.2 Explaining TRAC
D.2.1 The TRAC Interpreter
D.2.2 The Output Primitive
D.2.3 The Grammar Of TRAC
D.2.4 The Storage Primitive
D.2.5 The Recall Primitive
D.2.6 The Input Primitive
D.2.7 Parsing Arguments
D.2.8 Executing Discovered Primitives
D.2.9 Handling the Value String Produced
D.2.10 The Suffix Character
D.2.11 The Idling Script
D.2.12 Watching TRAC Operate
D.2.13 Tracing the Idling Script
D.2.14 Analyzing the Idling Script With Input
D.2.15 Tutoring Yourself With Trace
D.2.16 Writing Or Storing a Script Or Text
D.2.17 Listing Stored Objects
D.2.18 Storing Macro Forms
D.2.19 Writing Serious Scripts
Appendix E
TRAC Glossary