TITLE "Z3HZEX - Z3lib 4.0" ;================================================================ ; The Libraries, Version 4, (C) 1989 by Alpha Systems Corp. ;---------------------------------------------------------------- ; Author : Harold F. Bower ; Derived from Z3HZEX.Z80 Ver 1.1 by Richard Conn ; Date : 29 Mar 89 ; Version : 1.2 ; Module : Z3HZEX ; Abstract: This module contains the routine HALTZEX which ; aborts execution of the ZEX processor if executing ; Revision: ;- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ; Module Entry Points PUBLIC HALTZEX ; External References EXT GETZRUN, STRTZEX, GETZNC .Z80 CSEG ;=============================================================== ; NAME - HALTZEX ; Entry: - None ; Exit : A <> 0, Zero Flag Reset (NZ) If Ok ; A = 0, Zero Flag Set (Z) if ZEX Not Running ; Uses : AF ; Special Requirements: None ;=============================================================== HALTZEX: PUSH HL ; Save HL CALL GETZRUN ; Is ZEX running? POP HL RET Z PUSH HL CALL STRTZEX ; Resume ZEX execution if stopped CALL GETZNC ; Get ptr to next char for ZEX to return OR 0FFH ; ..Set Ok Return Flags LD (HL),A ; Set stop flag (FF) POP HL ; Get HL RET END