; ; Program: QUIET ; Author: Richard Conn ; Version: 1.0 ; Date: 29 Mar 84 ; version equ 10 z3env SET 0f400h ; ; QUIET is used to set and reset the Quiet Flag in ZCPR3. ; The forms of the command are: ; ; QUIET DISPLAY <-- Display Setting ; QUIET RESET <-- Turn Quiet Off ; QUIET SET <-- Turn Quiet On ; QUIET / <-- Print Help ; ; ; Equates ; fcb equ 5ch cr equ 0dh lf equ 0ah ; ; SYSLIB and Z3LIB Routines ; ext z3init,print,envptr ; ; Environment Definition ; if z3env ne 0 ; ; External ZCPR3 Environment Descriptor ; jmp start db 'Z3ENV' ;This is a ZCPR3 Utility db 1 ;External Environment Descriptor z3eadr: dw z3env start: lhld z3eadr ;pt to ZCPR3 environment ; else ; ; Internal ZCPR3 Environment Descriptor ; MACLIB Z3BASE.LIB MACLIB SYSENV.LIB z3eadr: jmp start SYSENV start: lxi h,z3eadr ;pt to ZCPR3 environment endif ; ; Start of Program -- Initialize ZCPR3 Environment ; call z3init ;initialize the ZCPR3 Env and the VLIB Env ; ; Print Banner ; call print db 'QUIET Version ' db (version/10)+'0','.',(version mod 10)+'0',0 ; ; Check for Command ; lda fcb+1 ;get first char cpi 'R' ;reset? jz qreset cpi 'S' ;set? jz qset cpi 'D' ;display? jz display ; ; Print help ; help: call print db cr,lf,'QUIET - Set/Reset/Display Quiet Flag' db cr,lf,'Syntax:' db cr,lf,' QUIET D or QUIET DIS - Display Quiet Flag' db cr,lf,' QUIET R or QUIET RES - Quiet Flag Off' db cr,lf,' QUIET S or QUIET SET - Quiet Flag On' db 0 ret ; ; Reset Quiet ; qreset: call ptquiet ;pt to Quiet Flag mvi m,0 ;reset it jmp display ; ; Set Quiet ; qset: call ptquiet ;pt to Quiet Flag mvi m,0ffh ;set it ; ; Display Quiet Flag ; display: call print db ' - Quiet Flag is ',0 call ptquiet ;pt to Quiet Flag mov a,m ;get it ora a ;0=reset jz disres call print db 'Set (On)',0 ret disres: call print db 'Reset (Off)',0 ret ; ; Return with HL pting to Quiet Flag ; ptquiet: lhld envptr ;pt to environment lxi d,28H ;offset to flag dad d ret end