TITLE "Z3GCL1 - Z3LIB 4.3a" NAME ('Z3GCL1') ; Name this module ;================================================================ ; The Libraries, Version 4, (C) 1989 by Alpha Systems Corp. ;---------------------------------------------------------------- ; Author : Richard Conn ; Date : ; Version : 1.1 ; Module : Z3GCL1 ; Abstract: This module contains the routine GETCL1 which returns ; the address and size of the ZCPR3 command line buffer. ; Revision: ; 1.2 - 22 Aug 90. Shorten it up a bit. No logical change. Joe Wright ;- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ; Module Entry Points PUBLIC GETCL1 ; External References EXT ENVPTR .Z80 CSEG ;=============================================================== ; NAME - GETCL1 ; Entry: - None ; Exit : A = Size of buffer in bytes ; HL - Points to the start of Command Line Buffer ; Uses : AF,HL ; Special Requirements: None ;=============================================================== ; Note: The command line buffer is structured as follows: ; ; cmdline: ; dw
; db ; db ; db ; db 0 GETCL1: PUSH DE ; Save DE LD HL,(ENVPTR) ; Pt to environment LD DE,18H ; Pt to entry ADD HL,DE LD E,(HL) ; Low order address to E INC HL LD D,(HL) ; High order to D INC HL LD A,(HL) ; Get size in A OR A ; Return with Zero Set if None EX DE,HL ; Z3CL address to HL POP DE ; Restore DE RET END