;ST.MAC is a testbed for the STATUS subroutine.
	.Z80

	ENTRY ST
	EXTERNAL STATUS
	GLOBAL STATE,MODE,CHAR
	GLOBAL ACTST,$ACTST,ARGST,$ARGST
	GLOBAL ENTST,$ENTST,FRMST,$FRMST,VALST,$VALST
	GLOBAL ALIST,$ALIST,FLIST,$FLIST,STACK,$STACK

	ASEG
	ORG 100H

ST:	LD HL,0
	ADD HL,SP
	LD (STKPTR),HL

	LD HL,$STK
	LD SP,HL

	CALL STATUS
	DB 'STATUS TEST$'
	LD HL,(STKPTR)
	LD SP,HL
	JP 0

STKPTR:	DW 0

STATE:	DW -1
MODE:	DB 0
CHAR:	DB '#'
ACTST:	DW 0
$ACTST:	DW 01H
ARGST:	DW 0FH
$ARGST:	DW 10H
ENTST:	DW 100H
$ENTST:	DW 1A0H
FRMST:	DW 0A00H
$FRMST:	DW 0AFFH
VALST:	DW 1000H
$VALST:	DW 1111H
ALIST:	DW 0A000H
$ALIST:	DW 0AAAAH
FLIST:	DW 0123H
$FLIST:	DW 1234H
STACK:	DW 0
$STACK:	DW 0FFFFH

STK:	DS 100
$STK	EQU $

	END ST
