80-Bus Journal

  

Juli/Aug. 1983 · Ausgabe 7/8

T-FORTH

von Gerhard Klement

Version 10.02.1983

IF
THEN
ELSE
BEGIN
UNTIL
WHILE
LOOP
DO

Ö---- T

Statement

Arg.

Ö--- T

Comment

X

DUP

-

x,x

Duplicate

Y,X

DROP

-

Y

Drop value

Y,X

SWAP

-

X,Y

Swap values

Y,X

OVER

-

Y,X,Y

Get 2nd value down

X,n

PICK

-

X,Val

Get n. Element T=1

Z,Y,X

ROT

-

Y,X,Z

Rotate down

-

CLEAR

-

-

Stackpointer to init. val

-

R

-

Val.

Copy from R Stack

X

ÜR

-

-

X to Rstack

-

-

X

X fron Rstack

Adr

§

-

Val

16 Bit load

Adr

-

Val

8 Bit load

Val,Adr

!

-

-

Store 16 bit val.

Val,Adr

C!

-

-

Store 8 bit val.

From,To,Len

CMOVE

-

-

Move

-

'

Name

Adr

Adr. of Constval

Val,Start,Len

FILL

-

-

Fill memory

-

ZERO

-

0

Const.

-

ONE

-

1

Const.

-

NEGONE

-

-1

Const.

X

MINUS

-

Conplm (X)

Complement of X

Y,X

+

-

Y+X

Sum

Y,X

-

-

Y-X

Difference

Y,X

*

-

Y*X

Product

Y,X

/

-

Y!X

Quotient

Y,X

MOD

- •

mod(Y/X)

Modulo i.e.remainder

Y,X

/MOD

-

Y/X,mod(X/Y)

Modulo

X

U

-

X+1

Increment

X

1-

-

X-1

Decrement

Val,Adr

+ !

-

-

Add to memory

-

STRING

Nase

Adr

Generate new string

-

STRI

Name

Adr

Genr. string var

Val

-

-

ROUT nuneric

Val

EMIT

-

-

ROUT ASCII

X

SGNOUT

-

-

ROUT signed integer

X

OUT£

-

-

ROUT HEX (X)

-

CR

-

-

ROUT CR

-

CLS

-

-

Clear Screen

Lin,Col

SCREEN

-

-

Set Cursor

-

SPACE

-

-

ROUT blank

Adr

?

-

-

ROUT Value at adr

Poistri

PRINTS

-

-

ROUT String

-

PROMPT

-

-

ROUT Ok stk CR

Val,Port

OUTPORT

-

-

Val to Port

X

CRT

-

-

Out X to CRT

-

ERROR

-

Adr.errstri

Set poi to err.string

Tab

.R

-

-

ROUT advance curs.

-

KEY

-

Val

RIN blink

-

RIN

-

Val

RIN no blink

-

£IN

HEX Val

Val

Convert HEX to bin

Port

INPORT

-

Val

Get value from port

-

CODBEG

-

Adr.codbeg

Constant

-

CODEADR

-

Adr.free

Constant

-

NEXTADR

-

Adr.nxtfnct

Constant

-

NADR

Name

Adr.dicnam

Constant

-

CONS

-

Adr.consfnct

Constant

-

VARBL

-

Adr.varbfnct

Constant

-

CADR

Name

Adr.code

Variable

-

SCODE

-

-

End TIL start MCODE

-

FORGET

Name

-

Delete incl. name


Seite 10 von 52